projects
/
fio.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
aa58d25
)
fix a weird check of the return value of aio_cancel.
author
YAMAMOTO Takashi
<yamamoto@valinux.co.jp>
Fri, 11 Jun 2010 07:21:33 +0000
(09:21 +0200)
committer
Jens Axboe
<jaxboe@fusionio.com>
Fri, 11 Jun 2010 07:21:33 +0000
(09:21 +0200)
i don't know what this 1 means in the first place but at least
it isn't portable. instead, check if the i/o has already
completed. (AIO_ALLDONE)
Signed-off-by: YAMAMOTO Takashi <yamamoto@valinux.co.jp>
Signed-off-by: Jens Axboe <jaxboe@fusionio.com>
engines/posixaio.c
patch
|
blob
|
blame
|
history
diff --git
a/engines/posixaio.c
b/engines/posixaio.c
index 70282f2975f660185fa832dcbf868850e011f0a1..7098d72677428d2dc314eb550f34129566ddc533 100644
(file)
--- a/
engines/posixaio.c
+++ b/
engines/posixaio.c
@@
-56,7
+56,7
@@
static int fio_posixaio_cancel(struct thread_data fio_unused *td,
struct fio_file *f = io_u->file;
int r = aio_cancel(f->fd, &io_u->aiocb);
- if (r ==
1
|| r == AIO_CANCELED)
+ if (r ==
AIO_ALLDONE
|| r == AIO_CANCELED)
return 0;
return 1;