lzip-bug
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Lzip-bug] Request for help with Windows version of Plzip.


From: Antonio Diaz Diaz
Subject: Re: [Lzip-bug] Request for help with Windows version of Plzip.
Date: Mon, 13 Jan 2020 16:49:57 +0100
User-agent: Mozilla/5.0 (X11; U; Linux i586; en-US; rv:1.9.1.19) Gecko/20110420 SeaMonkey/2.0.14

wrotycz wrote:
If it really is working as they say it would be reasonable to
differentiate between hacked for mingw version of pread()/pwrite() and
one shipped with Cygwin in this environment/platform. As far as I
recollect there were people here who used plzip under cygwin.

As far as I can remember, plzip compiles on Cygwin without problems (using the pread/pwrite functions provided by Cygwin). So I'm not sure the change you propose is needed.


/// not sure if cygwin defines __MSVCRT__

More reason to leave plzip unchanged until a real problem is found and a well documented fix is developed. What if I change the code and then it stops working on some systems?


3) This is just loosely related but I won't make new thread.
Description of preadblock() in `$plzip/decompress.cc' states
// Returns the number of bytes really read.
// If (returned value < size) and (errno == 0), means EOF was reached.

which is not accurate. Man for read()(https://linux.die.net/man/3/read)
and pread()(https://linux.die.net/man/3/pread) is clear about:

In what sense the references you provide prove that the comment about plzip's preadblock is not accurate? 'preadblock' is not 'pread'.


non-negative value returned indicates the number of bytes actually read,
so it's not an error per se, you should read again or check errno if
there was some interruption.

Which is exactly what preadblock does.


User-Agent: GWP-Draft
[...]
X-Draft-Contenttype: text/html

Please, reconfigure your mail program (Mail-User-Agent) to send messages to this list as 'text/plain'. I find it annoying when I receive a multipart message whose 'text/plain' part is just the 'text/html' part without newlines but with html character codes (like "that&#39;s" instead of "that's"). Thanks.

Antonio.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]