Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 9505
b: refs/heads/master
c: 353fb07
h: refs/heads/master
i:
  9503: 9f9b728
v: v3
  • Loading branch information
Zach Brown authored and Linus Torvalds committed Sep 30, 2005
1 parent 9103feb commit 066f379
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 897f15fb587fd2772b9e7ff6ec0265057f3c3975
refs/heads/master: 353fb07e2043d2df12dddf4e2c39552d0ab9b026
4 changes: 2 additions & 2 deletions trunk/fs/aio.c
Original file line number Diff line number Diff line change
Expand Up @@ -1347,7 +1347,7 @@ static ssize_t aio_pread(struct kiocb *iocb)
* regular files we retry till we complete the entire read or
* find that we can't read any more data (e.g short reads).
*/
} while (ret > 0 &&
} while (ret > 0 && iocb->ki_left > 0 &&
!S_ISFIFO(inode->i_mode) && !S_ISSOCK(inode->i_mode));

/* This means we must have transferred all that we could */
Expand All @@ -1371,7 +1371,7 @@ static ssize_t aio_pwrite(struct kiocb *iocb)
iocb->ki_buf += ret;
iocb->ki_left -= ret;
}
} while (ret > 0);
} while (ret > 0 && iocb->ki_left > 0);

if ((ret == 0) || (iocb->ki_left == 0))
ret = iocb->ki_nbytes - iocb->ki_left;
Expand Down

0 comments on commit 066f379

Please sign in to comment.