Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Hide xbt_cfg cruft from smpi tesh files.
[simgrid.git] / teshsuite / smpi / macro-shared / macro-shared.c
index 5c3ee9fe5d5efb2dfdd8338026edea21e4d26cdc..d1d9966e826d3992a776ef4658b436a8037d7bf6 100644 (file)
@@ -16,10 +16,11 @@ static void* hash(char *str, uint64_t* ans)
   char *tohash = str;
   *ans=5381;
   printf("hashing !\n");
-  int c = *(tohash++);
+  int c = *tohash;
   while (c != 0) {
     *ans = ((*ans << 5) + *ans) + c; /* hash * 33 + c */
-    c    = *(tohash++);
+    tohash++;
+    c = *tohash;
   }
   return NULL;
 }