summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMichal Schmidt <mschmidt@redhat.com>2013-03-02 12:44:41 +0100
committerMichal Schmidt <mschmidt@redhat.com>2013-03-02 12:57:42 +0100
commite970a72e94413d9011d510c97eadfdc85c96ccc0 (patch)
tree5e3f175162d5d7fcfa1049858a68953da21f3402 /src
parent6b19ad24d3b6ade48d9e3d29e5348fc6b8d7c811 (diff)
manager: turn a superfluous check into assert
The crash that the check prevented has been fixed by commit 9e9e2b7.
Diffstat (limited to 'src')
-rw-r--r--src/core/manager.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/core/manager.c b/src/core/manager.c
index d976581c96..91d773c2f6 100644
--- a/src/core/manager.c
+++ b/src/core/manager.c
@@ -269,8 +269,9 @@ static void manager_print_jobs_in_progress(Manager *m) {
if (j->state == JOB_RUNNING && counter++ == print_nr)
break;
- if (!j)
- return;
+ /* m->n_running_jobs must be consistent with the contents of m->jobs,
+ * so the above loop must have succeeded in finding j. */
+ assert(counter == print_nr + 1);
cylon_pos = m->jobs_in_progress_iteration % 14;
if (cylon_pos >= 8)