Make sure to return errors if we have any.
Submitted by: Pawel Jakub Dawidek <nick@garage.freebsd.pl>
This commit is contained in:
parent
8ad1f5e470
commit
c12ec49eda
@ -447,7 +447,7 @@ g_ccd_start(struct bio *bp)
|
||||
err = ccdbuffer(cbp, cs, bp, bn, addr, bcount);
|
||||
if (err) {
|
||||
bp->bio_completed += bcount;
|
||||
if (bp->bio_error != 0)
|
||||
if (bp->bio_error == 0)
|
||||
bp->bio_error = err;
|
||||
if (bp->bio_completed == bp->bio_length)
|
||||
g_io_deliver(bp, bp->bio_error);
|
||||
|
Loading…
x
Reference in New Issue
Block a user