~ubuntu-branches/ubuntu/trusty/rsyslog/trusty

« back to all changes in this revision

Viewing changes to runtime/stream.h

  • Committer: Dave Walker (Daviey)
  • Author(s): Scott Moser
  • Date: 2011-06-17 20:59:38 UTC
  • mfrom: (36.1.8 oneiric.merge)
  • Revision ID: davewalker@ubuntu.com-20110617205938-pfkizxz2wsgzi2ot
Tags: 5.8.1-1ubuntu1
* Resynchronise with Debian (LP: #794230).  Remaining changes:
  - Run as rsyslog:rsyslog, set $FileOwner to syslog
  - Replace init script with debian/rsyslog.upstart.
  - debian/rsyslog.logrotate: Use reload command to restart rsyslog
  - debian/rsyslog.conf: enable $RepeatedMsgReduction 
    to avoid bloating the syslog file (LP #453444)
  - Add debian/rsyslog.dmesg.upstart to save initial dmesg into a file.
    Install it in debian/rules.
  - debian/50-default.conf: set of default rules for syslog (forwarded to
    Debian #603160). remove file in postrm on purge. manage with ucf.
  - debian/rules: build with LDFLAGS=""
* Dropped:
  - debian/control: Bump build-dependency on debhelper
    debian now depends on dh >= 8
* New upstream release.
* Bump Standards-Version to 3.9.2. No further changes.
* Enable and install impstats module. (Closes: #620114)
* Update logcheck rule. (Closes: #616659)
* debian/rsyslog.init: Set correct compat level (5).
* The way rsyslog processes SIGHUP has changed. It no longer does a reload
  of its configuration, but simply closes all open files. To apply a changed
  configuration, rsyslogd needs to be restarted now.
  - Drop "reload" action from debian/rsyslog.init, map "force-reload" to
    "restart". (Closes: #580897)
  - Add "rotate" action to debian/rsyslog.init which sends SIGHUP to
    rsyslogd. Use that in debian/rsyslog.logrotate. (Closes: #626365)
  - Update debian/rsyslog-mysql.postinst and rsyslog-pgsql.postinst to use
    restart instead of reload.
  - Add a NEWS file explaining the changed SIGHUP handling.
* New upstream stable release.
* New upstream release.
  - Properly handle ANSI SQL strings in ompgsql. (Closes: #600479)
* New upstream release.
* debian/patches/02-pmaixforwardedfrom_type_nokeep.patch
  - Remove, merged upstream.
* debian/patches/03-epoll_create1-fallback.patch
  - Remove, merged upstream.
* debian/patches/03-epoll_create1-fallback.patch
  - If epoll_create1() is not available during runtime, fall back to
    epoll_create(). This fixes remote syslog when runnig rsyslog on a
    lenny kernel. (Closes: #617996)
* New upstream release.
* debian/rsyslog.links
  - Create symlink for rsyslog.service in multi-user.target.wants so rsyslog
    is enabled by default when using systemd.
* debian/patches/02-pmaixforwardedfrom_type_nokeep.patch
  - Fix build failure in aixforwardedfrom parser module by setting the
    module type to NOKEEP.
* debian/rsyslog.preinst
  - Remove old rsyslog.socket symlink from sockets.target.wants on upgrades
    as rsyslog uses syslog.socket now which is provided by systemd.
* debian/rsyslog.install
  - Stop installing rsyslog.socket.
* New upstream release.
* New upstream release.
  - Fix regression in imuxsock plugin which did no longer sanitize received
    messages. This makes 02-cleanup-trailing-lf.patch obsolete and also
    fixes the SQL syntax errors in the mysql output if the input contained
    NUL bytes. Closes: #614061
* Enable and install omprog output plugin. Closes: #552095
* Improve package description. Closes: #612948
  Thanks to Justin B Rye for the patch.
* debian/patches/02-cleanup-trailing-lf.patch
  - Fix regression in imuxsock plugin which did not remove a trailing LF
    anymore. Patch cherry-picked from upstream Git. Closes: #612829
* New upstream release.
* Enable and install parser modules.
* New upstream release.
* Upload to unstable.
* debian/patches/02-typo_fix_equation_sign.patch
  - Removed, merged upstream.
* debian/patches/03-atomic_operations.patch
  - Removed, merged upstream.
* debian/patches/03-atomic_operations.patch
  - Fix build failures on platforms which don't have 64 bit atomic
    operations. Patch cherry-picked from upstream Git. Closes: #600930
* New upstream development release.
* Remove patches, merged upstream
  - debian/patches/02-install_also_rsyslog_socket.patch
  - debian/patches/02-tls_loop_fix.patch
* debian/patches/02-typo_fix_equation_sign.patch
  - Fix small typo ("equation sign"). Closes: #575589
* debian/rsyslog.postinst
  - Remove pre-lenny migration code to rotate old log files from sysklogd.
* New upstream development release.
* debian/rsyslog.install
  - Install omruleset.so plugin: http://www.rsyslog.com/doc/omruleset.html
* debian/rsyslog.default
  - Start rsyslogd with native -c5 mode.
* Install systemd unit files which allow to run rsyslog in socket activation
  mode when systemd is used.
* debian/patches/02-install_also_rsyslog_socket.patch
  - When enabling rsyslog.service also enable rsyslog.socket. Patch
    cherry-picked from upstream Git.
* Bump debhelper compatibility level to 8. Update Build-Depends accordingly.

Show diffs side-by-side

added added

removed removed

Lines of Context:
102
102
        int64 iMaxFileSize;/* maximum size a file may grow to */
103
103
        int iMaxFiles;  /* maximum number of files if a circular mode is in use */
104
104
        int iFileNumDigits;/* min number of digits to use in file number (only in circular mode) */
105
 
        bool bDeleteOnClose; /* set to 1 to auto-delete on close -- be careful with that setting! */
 
105
        sbool bDeleteOnClose; /* set to 1 to auto-delete on close -- be careful with that setting! */
106
106
        int64 iCurrOffs;/* current offset */
107
107
        int64 *pUsrWCntr; /* NULL or a user-provided counter that receives the nbr of bytes written since the last CntrSet() */
108
108
        /* dynamic properties, valid only during file open, not to be persistet */
109
 
        bool bDisabled; /* should file no longer be written to? (currently set only if omfile file size limit fails) */
110
 
        bool bSync;     /* sync this file after every write? */
 
109
        sbool bDisabled; /* should file no longer be written to? (currently set only if omfile file size limit fails) */
 
110
        sbool bSync;    /* sync this file after every write? */
111
111
        size_t sIOBufSize;/* size of IO buffer */
112
112
        uchar *pszDir; /* Directory */
113
113
        int lenDir;
118
118
        size_t iBufPtrMax;      /* current max Ptr in Buffer (if partial read!) */
119
119
        size_t iBufPtr; /* pointer into current buffer */
120
120
        int iUngetC;    /* char set via UngetChar() call or -1 if none set */
121
 
        bool bInRecord; /* if 1, indicates that we are currently writing a not-yet complete record */
 
121
        sbool bInRecord;        /* if 1, indicates that we are currently writing a not-yet complete record */
122
122
        int iZipLevel;  /* zip level (0..9). If 0, zip is completely disabled */
123
123
        Bytef *pZipBuf;
124
124
        /* support for async flush procesing */
125
 
        bool bAsyncWrite;       /* do asynchronous writes (always if a flush interval is given) */
126
 
        bool bStopWriter;       /* shall writer thread terminate? */
127
 
        bool bDoTimedWait;      /* instruct writer thread to do a times wait to support flush timeouts */
 
125
        sbool bAsyncWrite;      /* do asynchronous writes (always if a flush interval is given) */
 
126
        sbool bStopWriter;      /* shall writer thread terminate? */
 
127
        sbool bDoTimedWait;     /* instruct writer thread to do a times wait to support flush timeouts */
128
128
        int iFlushInterval; /* flush in which interval - 0, no flushing */
129
129
        apc_id_t apcID;    /* id of current Apc request (used for cancelling) */
130
130
        pthread_mutex_t mut;/* mutex for flush in async mode */
143
143
        /* support for omfile size-limiting commands, special counters, NOT persisted! */
144
144
        off_t   iSizeLimit;     /* file size limit, 0 = no limit */
145
145
        uchar   *pszSizeLimitCmd;       /* command to carry out when size limit is reached */
146
 
        bool    bIsTTY;         /* is this a tty file? */
 
146
        sbool   bIsTTY;         /* is this a tty file? */
147
147
} strm_t;
148
148
 
149
149
 
156
156
        rsRetVal (*SetFileName)(strm_t *pThis, uchar *pszName, size_t iLenName);
157
157
        rsRetVal (*ReadChar)(strm_t *pThis, uchar *pC);
158
158
        rsRetVal (*UnreadChar)(strm_t *pThis, uchar c);
159
 
        rsRetVal (*ReadLine)(strm_t *pThis, cstr_t **ppCStr);
160
159
        rsRetVal (*SeekCurrOffs)(strm_t *pThis);
161
160
        rsRetVal (*Write)(strm_t *pThis, uchar *pBuf, size_t lenBuf);
162
161
        rsRetVal (*WriteChar)(strm_t *pThis, uchar c);
169
168
        rsRetVal (*Serialize)(strm_t *pThis, strm_t *pStrm);
170
169
        rsRetVal (*GetCurrOffset)(strm_t *pThis, int64 *pOffs);
171
170
        rsRetVal (*SetWCntr)(strm_t *pThis, number_t *pWCnt);
 
171
        rsRetVal (*Dup)(strm_t *pThis, strm_t **ppNew);
172
172
        INTERFACEpropSetMeth(strm, bDeleteOnClose, int);
173
173
        INTERFACEpropSetMeth(strm, iMaxFileSize, int);
174
174
        INTERFACEpropSetMeth(strm, iMaxFiles, int);
182
182
        INTERFACEpropSetMeth(strm, iSizeLimit, off_t);
183
183
        INTERFACEpropSetMeth(strm, iFlushInterval, int);
184
184
        INTERFACEpropSetMeth(strm, pszSizeLimitCmd, uchar*);
 
185
        /* v6 added */
 
186
        rsRetVal (*ReadLine)(strm_t *pThis, cstr_t **ppCStr, int mode);
185
187
ENDinterface(strm)
186
 
#define strmCURR_IF_VERSION 2 /* increment whenever you change the interface structure! */
 
188
#define strmCURR_IF_VERSION 6 /* increment whenever you change the interface structure! */
187
189
 
188
190
 
189
191
/* prototypes */