Skip to content

Panic in transfer's unwrap of downstairs_buffer #638

@leftwo

Description

@leftwo

In async fn transfer(..), this unwrap can panic:

                let responses = self.downstairs_buffer.remove(ds_id).unwrap();

If (I believe) we have three downstairs that have returned error (not skipped) none of them added
to the downstairs_buffer, and we get the unwrap() panic.

Update the code to better check for errors and if so, don't panic.

If at least one of the reads did succeed, and we should have a buffer, then we probably should
panic as that would mean something in crucible has lost the buffer and returning success to
the guest without giving them that buffer would be data corruption and we can't have that.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions