diff options
author | Rainer Gerhards <rgerhards@adiscon.com> | 2012-09-14 18:41:30 +0200 |
---|---|---|
committer | Rainer Gerhards <rgerhards@adiscon.com> | 2012-09-14 18:41:30 +0200 |
commit | 5df935249e85c842f5fcbd636d300c17ab31f0f5 (patch) | |
tree | c2fa61cf484f4a8b6c54905818376c55cb5ad37d /runtime/stream.h | |
parent | d7f26ff418237415834f5c34d10de120e16dc721 (diff) | |
download | rsyslog-5df935249e85c842f5fcbd636d300c17ab31f0f5.tar.gz rsyslog-5df935249e85c842f5fcbd636d300c17ab31f0f5.tar.bz2 rsyslog-5df935249e85c842f5fcbd636d300c17ab31f0f5.zip |
improved omfile zip writer to increase compression
This was achieved by somewhat reducing the robustness of the zip
archive. This is controlled by the new setting $OMFileVeryReliableZip.
Diffstat (limited to 'runtime/stream.h')
-rw-r--r-- | runtime/stream.h | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/runtime/stream.h b/runtime/stream.h index 60c68cb2..4de95db3 100644 --- a/runtime/stream.h +++ b/runtime/stream.h @@ -125,6 +125,8 @@ typedef struct strm_s { sbool bAsyncWrite; /* do asynchronous writes (always if a flush interval is given) */ sbool bStopWriter; /* shall writer thread terminate? */ sbool bDoTimedWait; /* instruct writer thread to do a times wait to support flush timeouts */ + sbool bzInitDone; /* did we do an init of zstrm already? */ + sbool bVeryReliableZip; /* shall we write interim headers to create a very reliable ZIP file? */ int iFlushInterval; /* flush in which interval - 0, no flushing */ apc_id_t apcID; /* id of current Apc request (used for cancelling) */ pthread_mutex_t mut;/* mutex for flush in async mode */ @@ -134,6 +136,7 @@ typedef struct strm_s { unsigned short iEnq; /* this MUST be unsigned as we use module arithmetic (else invalid indexing happens!) */ unsigned short iDeq; /* this MUST be unsigned as we use module arithmetic (else invalid indexing happens!) */ short iCnt; /* current nbr of elements in buffer */ + z_stream zstrm; /* zip stream to use */ struct { uchar *pBuf; size_t lenBuf; @@ -184,8 +187,10 @@ BEGINinterface(strm) /* name must also be changed in ENDinterface macro! */ INTERFACEpropSetMeth(strm, pszSizeLimitCmd, uchar*); /* v6 added */ rsRetVal (*ReadLine)(strm_t *pThis, cstr_t **ppCStr, int mode); + /* v7 added 2012-09-14 */ + INTERFACEpropSetMeth(strm, bVeryReliableZip, int); ENDinterface(strm) -#define strmCURR_IF_VERSION 6 /* increment whenever you change the interface structure! */ +#define strmCURR_IF_VERSION 7 /* increment whenever you change the interface structure! */ /* prototypes */ |