Ad Widget

Collapse

SNMP polling of ip address values segfault in 1.1beta7

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • zarath
    Junior Member
    • Jan 2006
    • 5

    #1

    SNMP polling of ip address values segfault in 1.1beta7

    There is a glitch in check_snmp.c,

    char *ip is not assigned in line 370.

    so i added the comment line a few line above prior to the sprintf:

    --- zabbix-1.1beta7.orig/src/zabbix_server/poller/checks_snmp.c
    +++ zabbix-1.1beta7/src/zabbix_server/poller/checks_snmp.c
    @@ -367,6 +367,7 @@
    p = malloc(16);
    if(p)
    {
    + ip = vars->val.string;
    snprintf(p,MAX_STRING_LEN-1,"%d.%d.%d.%d",ip[0],ip[1],ip[2],ip[3]);
    SET_STR_RESULT(value, p);

    ---------------------

    ciao
    Holger
    Last edited by zarath; 01-04-2006, 18:21. Reason: Even in 1.1beta8
Working...