[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [bug-inetutils] small syslogd and IPv6 conf issue
From: |
Alfred M. Szmidt |
Subject: |
Re: [bug-inetutils] small syslogd and IPv6 conf issue |
Date: |
Sat, 13 Oct 2012 08:32:36 -0400 |
I'm using inetutils/syslogd 1.9.1 with eglibc 2.15. It appears
that getaddrinfo with IPv6 is sensitive to trailing spaces and
comments, where-as IPv4 addresses are not.
For example, syslogd/getaddrinfo handles this fine:
local0.* @1.2.3.4 #COMMENT
But it cannot parse this line successfully:
Local0.* @FE80::215:5DFF:FE73:2F00 #COMMENT
The fact that IPv4 works above may be an unintended consequence of
getaddrinfo behavior, but I have found that it has been beneficial
in my application development. The patch below will allow IPv6 to
behave the same way and should allow any config line to include a
comment at the end.
Hi Thomas, thank you for your bug report!
Strictly speak (i.e. evoking UNIX tradition), comments in syslog.conf
are only valid at the beginning of the line. So neither of those
lines are ok. The reason for that is that the hash sign is a valid
file name, i.e. it is completely valid to write use the following:
local0.* /var/log/#messages#
and expect the file /var/log/#messages# to exist with log data. So
with this patch, the above is not valid any more, and to make it valid
one would need to add quoting rules.
Thus, sadly, I am not sure if we should apply this as is.