[v4,0/7] Refactor syslog implementation

Message ID 20220321150838.898597-1-adhemerval.zanella@linaro.org
Headers
Series Refactor syslog implementation |

Message

Adhemerval Zanella Netto March 21, 2022, 3:08 p.m. UTC
  The main driver of this change is to move away of using 32-bit
timestamps.  Based on discussion where systemd should support
RFC5424 [1], it decided to move away from implementing on glibc [2]
and just replace the use of localtime by gmtime.  It is a deviation
from RFC3164, but it improves some corner cases [3].

[1] https://github.com/systemd/systemd/issues/19251
[2] https://sourceware.org/pipermail/libc-alpha/2022-February/136595.html
[3] https://sourceware.org/pipermail/libc-alpha/2021-March/123583.html

Adhemerval Zanella (7):
  support: Add xmkfifo
  misc: Add syslog test
  misc: syslog: Fix indentation and style
  misc: syslog: Simplify implementation
  misc: syslog: Use fixed-sized buffer and remove memstream
  misc: syslog: Move SYSLOG_NAME to USE_MISC (BZ #16355)
  misc: Use gmtime instead of localtime

 misc/Makefile     |   2 +
 misc/sys/syslog.h |   4 +-
 misc/syslog.c     | 477 ++++++++++++++++++++++------------------------
 misc/tst-syslog.c | 477 ++++++++++++++++++++++++++++++++++++++++++++++
 support/Makefile  |   1 +
 support/xmkfifo.c |  29 +++
 support/xunistd.h |   1 +
 7 files changed, 745 insertions(+), 246 deletions(-)
 create mode 100644 misc/tst-syslog.c
 create mode 100644 support/xmkfifo.c
  

Comments

Paul Eggert March 21, 2022, 5:58 p.m. UTC | #1
Thanks for the updates. This all looks good to me.
  
Adhemerval Zanella Netto March 21, 2022, 8:16 p.m. UTC | #2
On 21/03/2022 14:58, Paul Eggert wrote:
> Thanks for the updates. This all looks good to me.

Thanks for checking on this Paul.  Recently on systemd discussion [1], it seems
that using gmtime without embedding timezone displacement would potentially 
cause regression.  So I will send another version that just fix the y2038 
issue while keeping using localtime.

[1] https://github.com/systemd/systemd/issues/19251