Przeglądaj źródła

xhttp_pi: proper sizeof for memset

Ovidiu Sas 11 lat temu
rodzic
commit
613d188f92
1 zmienionych plików z 1 dodań i 1 usunięć
  1. 1 1
      modules/xhttp_pi/xhttp_pi_fnc.c

+ 1 - 1
modules/xhttp_pi/xhttp_pi_fnc.c

@@ -889,7 +889,7 @@ int ph_getColVals(ph_mod_t *module, ph_cmd_t *cmd,
 			if(vals==NULL||ids==NULL) {LM_ERR("oom\n"); return -1;}
 			col_vals = vals; col_ids = ids;
 			vals = &col_vals[size]; ids = &col_ids[size];
-			memset(vals, 0, sizeof(str*)); memset(ids, 0, sizeof(str*));
+			memset(vals, 0, sizeof(str)); memset(ids, 0, sizeof(str));
 			/* Retrieve the node attribute */
 			attr.s = ph_xmlNodeGetAttrContentByName(node,
 							XHTTP_PI_XML_ID_ATTR);