From: suter Date: Wed, 25 Sep 2013 12:18:46 +0000 (+0200) Subject: some corrections while chasing leaks X-Git-Tag: v3_9_90~86 X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/commitdiff_plain/a40433ce2cb82338f078c3b2f1a97b89ccf1b13e some corrections while chasing leaks --- diff --git a/src/simdag/sd_global.c b/src/simdag/sd_global.c index 8329d4f67b..400d0c818f 100644 --- a/src/simdag/sd_global.c +++ b/src/simdag/sd_global.c @@ -221,8 +221,8 @@ void SD_create_environment(const char *platform_file) } xbt_lib_foreach(storage_lib, cursor, name, surf_storage) { - if(surf_storage[SURF_LINK_LEVEL]) - __SD_storage_create(surf_link[SURF_STORAGE_LEVEL], NULL); + if(surf_storage[SURF_STORAGE_LEVEL]) + __SD_storage_create(surf_storage[SURF_STORAGE_LEVEL], NULL); } diff --git a/src/simdag/sd_workstation.c b/src/simdag/sd_workstation.c index fdc07befef..4a491d7f2a 100644 --- a/src/simdag/sd_workstation.c +++ b/src/simdag/sd_workstation.c @@ -57,7 +57,10 @@ SD_storage_t __SD_storage_create(void *surf_storage, void *data) */ void __SD_storage_destroy(void *storage) { - xbt_free(storage); + SD_storage_priv_t s; + + s = (SD_storage_priv_t) storage; + xbt_free(s); } /**