Print these errors after all
This commit is contained in:
parent
9b7138b3b1
commit
ad1d6afbba
@ -273,10 +273,8 @@ int rw_flag; /* READING or WRITING */
|
|||||||
if (r != block_size) {
|
if (r != block_size) {
|
||||||
if (r >= 0) r = END_OF_FILE;
|
if (r >= 0) r = END_OF_FILE;
|
||||||
if (r != END_OF_FILE)
|
if (r != END_OF_FILE)
|
||||||
#if FS_ERRORS
|
|
||||||
printf("Unrecoverable disk error on device %d/%d, block %ld\n",
|
printf("Unrecoverable disk error on device %d/%d, block %ld\n",
|
||||||
(dev>>MAJOR)&BYTE, (dev>>MINOR)&BYTE, bp->b_blocknr);
|
(dev>>MAJOR)&BYTE, (dev>>MINOR)&BYTE, bp->b_blocknr);
|
||||||
#endif
|
|
||||||
bp->b_dev = NO_DEV; /* invalidate block */
|
bp->b_dev = NO_DEV; /* invalidate block */
|
||||||
|
|
||||||
/* Report read errors to interested parties. */
|
/* Report read errors to interested parties. */
|
||||||
@ -383,12 +381,10 @@ int rw_flag; /* READING or WRITING */
|
|||||||
if (iop->iov_size != 0) {
|
if (iop->iov_size != 0) {
|
||||||
/* Transfer failed. An error? Do we care? */
|
/* Transfer failed. An error? Do we care? */
|
||||||
if (r != OK && i == 0) {
|
if (r != OK && i == 0) {
|
||||||
#if FS_ERRORS
|
|
||||||
printf(
|
printf(
|
||||||
"fs: I/O error on device %d/%d, block %lu\n",
|
"fs: I/O error on device %d/%d, block %lu\n",
|
||||||
(dev>>MAJOR)&BYTE, (dev>>MINOR)&BYTE,
|
(dev>>MAJOR)&BYTE, (dev>>MINOR)&BYTE,
|
||||||
bp->b_blocknr);
|
bp->b_blocknr);
|
||||||
#endif
|
|
||||||
bp->b_dev = NO_DEV; /* invalidate block */
|
bp->b_dev = NO_DEV; /* invalidate block */
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user