瀏覽代碼

Fix a division by zero.

With --enable-slow-machine, we often divide variables by a large number. We should make sure the result is larger than 0.
Cyril Roelandt 13 年之前
父節點
當前提交
a0b69c2602
共有 1 個文件被更改,包括 2 次插入0 次删除
  1. 2 0
      tests/datawizard/reclaim.c

+ 2 - 0
tests/datawizard/reclaim.c

@@ -88,6 +88,8 @@ int main(int argc, char **argv)
 
 #ifdef STARPU_SLOW_MACHINE
 	mb /= 100;
+	if (mb == 0)
+		mb = 1;
 	ntasks /= 100;
 #endif