Assorted changes
* include/mailutils/debug.h (mu_debug_format_spec): New function. * include/mailutils/stream.h (MU_IOCTL_SYSLOGSTREAM) (MU_IOCTL_FILTER): New ioctls. (MU_IOCTL_LOGSTREAM_GET_SEVERITY_MASK) (MU_IOCTL_LOGSTREAM_SET_SEVERITY_MASK) (MU_IOCTL_LOGSTREAM_CLONE) (MU_IOCTL_SYSLOGSTREAM_SET_LOGGER) (MU_IOCTL_SYSLOGSTREAM_GET_LOGGER) (MU_IOCTL_FILTER_GET_DISABLED) (MU_IOCTL_FILTER_SET_DISABLED): And their opcodes. * include/mailutils/sys/filter.h (_MU_FILTER_DISABLED) (_MU_FILTER_EOF): New defines. (_mu_filter_stream) <eof>: Replace with fltflag (a bitmask). * include/mailutils/sys/logstream.h (_mu_log_stream) <sevmask>: New member. * include/mailutils/sys/syslogstream.h (_mu_syslog_stream) <logger>: New member. * include/mailutils/util.h (mu_onexit_run): New proto. * libmailutils/base/onexit.c (_mu_onexit_run): Extra safety check. (mu_onexit_run): New function. (mu_debug_level_str): New static. (mu_debug_format_spec): New function. * libmailutils/stream/fltstream.c (filter_read, filter_write): Bypass the xcoder if _MU_FILTER_DISABLED is set. Use fltflag instead of the removed eof. (filter_ctl): Handle MU_IOCTL_FILTER. * libmailutils/stream/logstream.c (_log_write): The sevmask member masks out severity prefix output for certain severities. (_log_ctl): Handle new opcodes (see above). * libmailutils/stream/syslogstream.c (_syslog_stream_write): Use <logger>, if supplied, instead of the system syslog(3). (_syslog_ctl): Handle MU_IOCTL_SYSLOGSTREAM. (mu_syslog_stream_create): Initialize logger to NULL. * mu/ldflags.c (lib_descr): Protect entries with the corresponding #ifdef ENABLE_whatever.
Showing
12 changed files
with
274 additions
and
35 deletions
-
Please register or sign in to post a comment