1
0
forked from 0ad/0ad

file_wait_io: -EINPROGRESS => EINPROGRESS, removed stray bytes_transferred assertion

This was SVN commit r196.
This commit is contained in:
Simon Brenner 2004-04-09 12:38:16 +00:00
parent ffb2b20985
commit 89ab9643dc

View File

@ -656,11 +656,10 @@ int file_wait_io(const Handle hio, void*& p, size_t& size)
// wait for transfer to complete // wait for transfer to complete
{ {
while(aio_error(cb) == -EINPROGRESS) while(aio_error(cb) == EINPROGRESS)
aio_suspend(&cb, 1, NULL); aio_suspend(&cb, 1, NULL);
bytes_transferred = aio_return(cb); bytes_transferred = aio_return(cb);
assert(bytes_transferred == BLOCK_SIZE);
ret = bytes_transferred? 0 : -1; ret = bytes_transferred? 0 : -1;
} }
skip_wait: skip_wait: