]> AND Public Git Repository - simgrid.git/blobdiff - src/xbt/dynar.c
Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
xbt_dict: allow to have integer key and data
[simgrid.git] / src / xbt / dynar.c
index f48533938e19a6b5a5f9c55b29374aed8b85d678..906434b62cd7c7a4eb65d361eedb137409aebc9f 100644 (file)
@@ -89,7 +89,6 @@ static XBT_INLINE
     char *const old_data = (char *) dynar->data;
 
     const unsigned long elmsize = dynar->elmsize;
-    const unsigned long old_length = old_size * elmsize;
 
     const unsigned long used = dynar->used;
     const unsigned long used_length = used * elmsize;
@@ -104,7 +103,6 @@ static XBT_INLINE
 
     if (old_data) {
       memcpy(new_data, old_data, used_length);
-      _xbt_clear_mem(old_data, old_length);
       free(old_data);
     }