summaryrefslogtreecommitdiffstats
path: root/usr.bin
diff options
context:
space:
mode:
authoradrian <adrian@FreeBSD.org>2011-10-04 14:26:45 +0000
committeradrian <adrian@FreeBSD.org>2011-10-04 14:26:45 +0000
commitb7672d6f5ec484e1580a003f39104c7b3d38b74c (patch)
treeb4c8bb7621373e33d8c53f198d2116453176125d /usr.bin
parent069abf93c2a4ea0b586910723be6bf11cebe442e (diff)
downloadFreeBSD-src-b7672d6f5ec484e1580a003f39104c7b3d38b74c.zip
FreeBSD-src-b7672d6f5ec484e1580a003f39104c7b3d38b74c.tar.gz
Handle the situation where fixups_close() has been called but more fixups
are still available on the queue. Without this, the fixups producer/consumer pipeline will artifically terminate before all of the fixups have been processed, leading to incomplete updates and generally quite unhappy users. Submitted by: mux
Diffstat (limited to 'usr.bin')
-rw-r--r--usr.bin/csup/fixups.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/usr.bin/csup/fixups.c b/usr.bin/csup/fixups.c
index b105a8f..a83ad1c 100644
--- a/usr.bin/csup/fixups.c
+++ b/usr.bin/csup/fixups.c
@@ -141,7 +141,7 @@ fixups_get(struct fixups *f)
fixups_lock(f);
while (f->size == 0 && !f->closed)
pthread_cond_wait(&f->cond, &f->lock);
- if (f->closed) {
+ if (f->closed && f->size == 0) {
fixups_unlock(f);
return (NULL);
}
OpenPOWER on IntegriCloud