Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Use correct modifier, and don't lie about pointer type.
authorArnaud Giersch <arnaud.giersch@iut-bm.univ-fcomte.fr>
Wed, 12 Jun 2013 09:49:54 +0000 (11:49 +0200)
committerArnaud Giersch <arnaud.giersch@iut-bm.univ-fcomte.fr>
Wed, 12 Jun 2013 09:57:20 +0000 (11:57 +0200)
src/surf/storage.c

index 98d74e7..2e4675a 100644 (file)
@@ -539,7 +539,7 @@ static xbt_dict_t parse_storage_content(char *filename, size_t *used_size)
 
   while ((read = xbt_getline(&line, &len, file)) != -1) {
     if (read){
-    if(sscanf(line,"%s %lu",path, (unsigned long*)&size)==2) {
+    if(sscanf(line,"%s %zu",path, &size)==2) {
         *used_size += size;
         xbt_dict_set(parse_content,path,(void*) size,NULL);
       } else {