Fixed random bugs in the runtime.
[repair.git] / Repair / RepairCompiler / MCC / Runtime / SimpleHash.h
index 50020d87d2d59328f4456a40974b5f7a4fd31a59..e1056f2c5a05b5bc210427b2f8ac0dfe62fec95d 100755 (executable)
@@ -135,11 +135,11 @@ class SimpleIterator {
       if (cur->nextarray==0 &&
          index==table->tailindex)
        return 0;
-      index++;
       if (index==ARRAYSIZE) {
        index=0;
        cur=cur->nextarray;
-      }
+      } else
+       index++;
     }
     if (cur->nodes[index].inuse)
       return 1;