diff options
Diffstat (limited to 'tools/perf/util/ordered-events.c')
-rw-r--r-- | tools/perf/util/ordered-events.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/tools/perf/util/ordered-events.c b/tools/perf/util/ordered-events.c index fd4be94125fb..077ddd25189f 100644 --- a/tools/perf/util/ordered-events.c +++ b/tools/perf/util/ordered-events.c | |||
@@ -166,7 +166,7 @@ static int __ordered_events__flush(struct perf_session *s, | |||
166 | struct ui_progress prog; | 166 | struct ui_progress prog; |
167 | int ret; | 167 | int ret; |
168 | 168 | ||
169 | if (!tool->ordered_events || !limit) | 169 | if (!limit) |
170 | return 0; | 170 | return 0; |
171 | 171 | ||
172 | if (show_progress) | 172 | if (show_progress) |
@@ -216,6 +216,9 @@ int ordered_events__flush(struct perf_session *s, struct perf_tool *tool, | |||
216 | }; | 216 | }; |
217 | int err; | 217 | int err; |
218 | 218 | ||
219 | if (oe->nr_events == 0) | ||
220 | return 0; | ||
221 | |||
219 | switch (how) { | 222 | switch (how) { |
220 | case OE_FLUSH__FINAL: | 223 | case OE_FLUSH__FINAL: |
221 | oe->next_flush = ULLONG_MAX; | 224 | oe->next_flush = ULLONG_MAX; |