View | Details | Raw Unified | Return to bug 219072 | Differences between
and this patch

Collapse All | Expand All

(-)agent/mibgroup/host/data_access/swrun_kinfo.c (-2 / +6 lines)
Lines 176-182 Link Here
176
netsnmp_arch_swrun_container_load( netsnmp_container *container, u_int flags)
176
netsnmp_arch_swrun_container_load( netsnmp_container *container, u_int flags)
177
{
177
{
178
    struct SWRUN_TABLE  *proc_table;
178
    struct SWRUN_TABLE  *proc_table;
179
    int                  nprocs, i, rc;
179
    int                  nprocs, i;
180
    char                 buf[BUFSIZ+1], **argv;
180
    char                 buf[BUFSIZ+1], **argv;
181
    netsnmp_swrun_entry *entry;
181
    netsnmp_swrun_entry *entry;
182
182
Lines 203-209 Link Here
203
        entry = netsnmp_swrun_entry_create(proc_table[i].SWRUN_K_PID);
203
        entry = netsnmp_swrun_entry_create(proc_table[i].SWRUN_K_PID);
204
        if (NULL == entry)
204
        if (NULL == entry)
205
            continue;   /* error already logged by function */
205
            continue;   /* error already logged by function */
206
        rc = CONTAINER_INSERT(container, entry);
206
        if ( -1 == CONTAINER_INSERT(container, entry)) {
207
	   // entry didn't get inserted (duplicate key)
208
	   free(entry); 
209
        }
210
207
211
208
        /*
212
        /*
209
         * There are two possible sources for the command being run:
213
         * There are two possible sources for the command being run:

Return to bug 219072