Hi Przemek,

Many thanks for the hunt and fix, it now works perfectly.

Now the remaining mystery is how 7-Zip could extract
the wrong file anyway :)

BTW, I wonder if we couldn't rather use hb_fs*() functions
instead of fopen/fread. (in places where this wouldn't
badly affect performance, like hb_zipGetFileInfo().) Or would
it have some other side effects?

Brgds,
Viktor

On 2008.07.31., at 22:51, Przemyslaw Czerpak wrote:

On Thu, 31 Jul 2008, Przemyslaw Czerpak wrote:

Hi Viktor,

You do not have too. I've just located the reason of problem.
Just simply I was not writting anything for DOS/Windows for
too long time. On this systems fopen() without "b" flag strip
'\r' from the stream so CRC was wrongly calculated for such
files. I'll commit fix in a while.

Please try after:

2008-07-31 22:49 UTC+0200 Przemyslaw Czerpak (druzus/at/ priv.onet.pl)
    * harbour/contrib/hbmzip/hbmzip.c
      ! added "b" to fopen() flags to force binary mode in all systems
        during CRC32 calculation

Sorry for troubles. It was my really stupid mistake.

best regards,
Przemek
_______________________________________________
Harbour mailing list
Harbour@harbour-project.org
http://lists.harbour-project.org/mailman/listinfo/harbour

_______________________________________________
Harbour mailing list
Harbour@harbour-project.org
http://lists.harbour-project.org/mailman/listinfo/harbour

Reply via email to