Commit Diff


commit - 2d67dc3aa72fb921c2b7ddcf2af6814acf2784c2
commit + a906b277aa501d5897960b8e9f4466450d91dcac
blob - c29bd335ba24926a633d0fdfb8bbfb2624c42d73
blob + 311c7e65273b2764eabc6160b3675b91e1165e9f
--- lib/pack_create_privsep.c
+++ lib/pack_create_privsep.c
@@ -447,17 +447,15 @@ got_pack_paint_commits(int *ncolored, struct got_objec
 				    ids, keep, drop, skip, repo,
 				    progress_cb, progress_arg, rl,
 				    cancel_cb, cancel_arg);
-				if (err && qid == NULL)
-					goto done;
 				if (qid) {
 					STAILQ_REMOVE(ids, qid,
 					    got_object_qid, entry);
 					nqueued--;
 					got_object_qid_free(qid);
 					qid = NULL;
-					if (err)
-						goto done;
-				}
+				}
+				if (err)
+					goto done;
 				continue;
 			}
 		}