about summary refs log tree commit diff
path: root/src/afl-fuzz-stats.c
diff options
context:
space:
mode:
authorvan Hauser <vh@thc.org>2020-04-11 09:16:30 +0200
committervan Hauser <vh@thc.org>2020-04-11 09:16:30 +0200
commitcc3ac932d9d255e8600ba58cb3a02c5ad43f5e8a (patch)
tree67fcdebdd6a62b5f47054d5d1f812ce2dc8601c0 /src/afl-fuzz-stats.c
parentd8947d1fa41c8fa12b2bf6a0ef128bd1d06b127e (diff)
downloadafl++-cc3ac932d9d255e8600ba58cb3a02c5ad43f5e8a.tar.gz
fix -E/-V
Diffstat (limited to 'src/afl-fuzz-stats.c')
-rw-r--r--src/afl-fuzz-stats.c22
1 files changed, 22 insertions, 0 deletions
diff --git a/src/afl-fuzz-stats.c b/src/afl-fuzz-stats.c
index 65876f67..2e680dbb 100644
--- a/src/afl-fuzz-stats.c
+++ b/src/afl-fuzz-stats.c
@@ -215,6 +215,28 @@ void show_stats(afl_state_t *afl) {
 
   cur_ms = get_cur_time();
 
+  if (afl->most_time_key) {
+
+    if (afl->most_time * 1000 < cur_ms - afl->start_time) {
+
+      afl->most_time_key = 2;
+      afl->stop_soon = 2;
+
+    }
+
+  }
+
+  if (afl->most_execs_key == 1) {
+
+    if (afl->most_execs <= afl->total_execs) {
+
+      afl->most_execs_key = 2;
+      afl->stop_soon = 2;
+
+    }
+
+  }
+
   /* If not enough time has passed since last UI update, bail out. */
 
   if (cur_ms - afl->stats_last_ms < 1000 / UI_TARGET_HZ &&