summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--tools/heapcheck/heapcheck_test.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/tools/heapcheck/heapcheck_test.py b/tools/heapcheck/heapcheck_test.py
index 80bd37c..90f145df 100644
--- a/tools/heapcheck/heapcheck_test.py
+++ b/tools/heapcheck/heapcheck_test.py
@@ -154,11 +154,11 @@ class HeapcheckWrapper(object):
for line in histo[count]:
print line
print '-----------------------------------------------------'
- if is_sane:
- return return_code
- else:
+ if check_sanity and not is_sane:
logging.error("Sanity check failed")
return 2
+ else:
+ return return_code
def RunTestsAndAnalyze(self, check_sanity):
self.Execute()