wine and asyncronous file i/o

Martin Fuchs martin-fuchs at gmx.net
Tue Nov 26 02:11:19 CST 2002


I have made an additional test with network files instead of files on the 
disk.

> To do it exactly like Windows, ReadFileEx() should check for a end-of-file
> condition.
> It there are any bytes to read from the file, it should return TRUE.
> After that, when the thread goes into the alertable state, the completition
> function
> should be called.
> In the other case, if ReadFileEx() finds EOF, it should call
> SetLastError(ERROR_HANDLE_EOF), and return FALSE. This is, what wine
> currently doesn't do.
>
> That's all. At least for regular files located on the hard disc.

I made this restriction, because I remembered, there was some thing.
And yes, there is: If you read the same files as before, but now using a 
network connect (even if the files are located on the same computer), now 
Windows behaves a bit different. The completition function IS called in this 
case with ERROR_HANDLE_EOF as parameter.

I think, this is the reason, why MSDN isn't as exact, as it could (or should) 
be. The behaviour in respect to calling the completition function depends on 
the type of dfriver, which is used to access the files.


-- 
Martin Fuchs
martin-fuchs at gmx.net



More information about the wine-devel mailing list