Welcome, Guest
Username: Password: Remember me
Components and Libraries for Networking Development, discussions, problems and suggestions
  • Page:
  • 1

TOPIC:

Indy Library Gzip compression 9 years 11 months ago #6506

  • Dinko
  • Dinko's Avatar Topic Author
  • Offline
  • Junior Member
  • Junior Member
  • Posts: 91
  • Thank you received: 5
Hello

I wrote some http server application for windows 64 /32 which use gzip indy compression to compress output.
Problem is that from time to time I get zlib error -5 when I try to compress some string.
In attachment you can find my isolated test case which proves that some string can not be compressed using Indy routines.
I thing this is bug inside Indy Library, and I need confirmation or fix. Any help is appreciated.

(*
The purpose of test is to show that Indy
library can not GZIP compress some string
String is saved in file uncompresable.xml
String is loaded into memory and
I cut peace of files and compresse it
After some time I found on peace which
cannot be compressed and program returns
zlib error -5 which means that buffer is
not good. If you change MemLevel from 9 to
lower values or compression level from 9 to
no lower values you can compress this string
but eventually if you try some other strings
you get the same result (-5).
Indy use zlib1.dll (ver 1.2.8) for 32 bit windows
and zlibwapi.dll (ver 1.2.5) for 64 bit windows
I think that something is wrong with Indy
implementation of compression and the way
how -5 error should be interpreted but I'm
not sure. I tried some other pascal zlib libraries
and everyhing is good.
Used version is Windows CodeTyphon 5.1.0, Fpc = 2.7.1,
pl_Indy Source (24-10-2014 SVN Rev 5201)
I appreciate any help from Indy team or CodeTyphon team or
Lazarus team
*)

dll._zip contain zlib1 for 32 windows and zlibwapi from 64 bit windows.
Rename and uncompress it if you do not have your own version.

Regards, Dinko
Attachments:

Please Log in or Create an account to join the conversation.

Indy Library Gzip compression 9 years 11 months ago #6507

  • Sternas Stefanos
  • Sternas Stefanos's Avatar
  • Offline
  • Moderator
  • Moderator
  • Ex Pilot, M.Sc, Ph.D
  • Posts: 4535
  • Thank you received: 1114
Sir, we will test this
PilotLogic Architect and Core Programmer

Please Log in or Create an account to join the conversation.

  • Page:
  • 1