Hi,
I tried to set the syslog parameters using -LS:
# /usr/sbin/snmpd -LS
Segmentation fault (core dumped)
# /usr/sbin/snmpd -LS3d
/usr/sbin/snmpd -LS3d
invalid syslog facility: H
Usage: /usr/sbin/snmpd [OPTIONS] [LISTENING ADDRESSES]
Version: 5.3.1
Web: http://www.net-snmp.org/
Email: [email protected]
[...]
So the documented behaviour does not work (and that is BTW a buffer
overflow, the 'H' shown above is the first letter of "HOSTNAME=<xxx>"
environment variable).
I'm pretty sure that the attached patch is what was meant to be in the
code. With this patch, -LS3d works fine.
Please apply.
Best regards
Henning
--
Henning P. Schmiedehausen -- [EMAIL PROTECTED] | J2EE, Linux,
91054 Buckenhof, Germany -- +49 9131 506540 | Apache person
Open Source Consulting, Development, Design | Velocity - Turbine guy
INTERMETA - Gesellschaft fuer Mehrwertdienste mbH - RG Fuerth, HRB 7350
Gesellschaftssitz: Buckenhof. Geschaeftsfuehrer: Henning Schmiedehausen
"It's good to be a lunatic..." -- 10th doctor
--- net-snmp-5.3.1/snmplib/snmp_logging.c~ 2007-10-14 18:23:09.000000000 +0200
+++ net-snmp-5.3.1/snmplib/snmp_logging.c 2007-10-14 18:53:15.000000000 +0200
@@ -376,7 +376,7 @@
case 'S':
priority = decode_priority( optarg, &pri_max );
if (priority == -1) return -1;
- optarg = argv[++optind];
+ optarg++;
/* Fallthrough */
case 's':
if (inc_optind)
-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems? Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________
Net-snmp-coders mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/net-snmp-coders