Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 19 Feb 2020 11:50:20 +0000
From:      bugzilla-noreply@freebsd.org
To:        bugs@FreeBSD.org
Subject:   [Bug 244226] [patch] syslogd converts all 8-bit chars to M-x sequences
Message-ID:  <bug-244226-227@https.bugs.freebsd.org/bugzilla/>

next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D244226

            Bug ID: 244226
           Summary: [patch] syslogd converts all 8-bit chars to M-x
                    sequences
           Product: Base System
           Version: CURRENT
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Some People
          Priority: ---
         Component: bin
          Assignee: bugs@FreeBSD.org
          Reporter: fbsd@opal.com

Created attachment 211760
  --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=3D211760&action=
=3Dedit
patch to add locale support to syslogd when converting strings to "safe"
sequences

syslogd has code to convert all logged messages to "safe" strings.

At the moment, the code converts control characters to "^x" sequences and A=
LL
8-bit characters to "M-x" sequences.  This means that printable characters =
in
character sets other than ASCII are converted and so do not display as expe=
cted
when viewing the logs.

This patch adds LC_CTYPE locale support to syslogd and changes the "safe"
conversion code to examine the logged characters using mbrtoc32() and to use
iswgraph() to test if a character needs converting to safe sequences.

It also uses vis() to do the conversion which is similar to OpenBSD but whi=
ch
means control chars become \C-x and non-graphical 8-bit chars become \M-x.

--=20
You are receiving this mail because:
You are the assignee for the bug.=



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-244226-227>