Let snmp_synch_response deal with PDU freeing
[collectd.git] / src / snmp.c
index 3e6cb91..b90e0ff 100644 (file)
@@ -1437,8 +1437,9 @@ static int csnmp_read_table (host_definition_t *host, data_definition_t *data)
     snmp_free_pdu (res);
   res = NULL;
 
-  if (req != NULL)
-    snmp_free_pdu (req);
+  /*
+   * memory is handled by snmp_synch_response
+   */
   req = NULL;
 
   if (status == 0)