From 8b034b7d18a08d3a2378e5b6fc9fbdd1b658f142 Mon Sep 17 00:00:00 2001 From: Paul Smith Date: Sun, 28 Apr 2013 17:31:46 -0400 Subject: Small cleanups and fixes. --- job.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'job.c') diff --git a/job.c b/job.c index 07d70c7..6ee6b8f 100644 --- a/job.c +++ b/job.c @@ -659,7 +659,7 @@ acquire_semaphore (void) fl.l_type = F_WRLCK; fl.l_whence = SEEK_SET; - fl.l_start = 0; /* lock just one byte */ + fl.l_start = 0; fl.l_len = 1; if (fcntl (sync_handle, F_SETLKW, &fl) != -1) return &fl; @@ -976,7 +976,7 @@ reap_children (int block, int err) /* Search for a child matching the deceased one. */ lastc = 0; for (c = children; c != 0; lastc = c, c = c->next) - if (c->remote == remote && c->pid == pid) + if (c->pid == pid && c->remote == remote) break; if (c == 0) -- cgit v1.2.3