소스 검색

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