Web lists-archives.com

Re: [Mingw-users] Missing pread, pwrite

Keith Marshall wrote:
> its immunity to race conditions when used in conjunction with open(),
> read(), and write() in distinct threads, and its proper handling of
> associated error conditions.

First of all, thanks for the answer, and sorry for the noise. I do not 
write Windows code. I was just forwarding a suggestion made in the 
mailing list of my own project[1].

The implementation I sent is indeed inadequate for general use. I was 
under the false impression that ReadFile/WriteFile were equivalent to 
pread/pwrite, but I have just been told that they are not. They modify 
the file position. They happen to work in plzip because the file is 
opened just once and calls to pread/pwrite are never mixed with calls to 

[1] http://lists.nongnu.org/archive/html/lzip-bug/2016-05/msg00007.html

Thanks for all your good work,

Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
MinGW-users mailing list

This list observes the Etiquette found at 
We ask that you be polite and do the same.  Disregard for the list etiquette may cause your account to be moderated.

You may change your MinGW Account Options or unsubscribe at:
Also: mailto:mingw-users-request@xxxxxxxxxxxxxxxxxxxxx?subject=unsubscribe