Commit Diff


commit - 6dbbfded937c923383970d564ff69f8c7eda2be4
commit + 965fcba660e4b5245c9fafb15153269228e11c9d
blob - c785f4694dfc78b3ad5b5064cb0471be8ad70fae
blob + bb8f5528cae936ef7441f805dd07923ad011329b
--- gotd/gotd.c
+++ gotd/gotd.c
@@ -1908,15 +1908,18 @@ gotd_dispatch(int fd, short event, void *arg)
 				disconnect_on_error(client, err);
 			else
 				disconnect(client);
-		} else if (do_packfile_install)
-			err = install_pack(client, proc->chroot_path, &imsg);
-		else if (do_ref_updates)
-			err = begin_ref_updates(client, &imsg);
-		else if (do_ref_update)
-			err = update_ref(client, proc->chroot_path, &imsg);
-
-		if (err)
-			log_warnx("uid %d: %s", client->euid, err->msg);
+		} else {
+			if (do_packfile_install)
+				err = install_pack(client, proc->chroot_path,
+				    &imsg);
+			else if (do_ref_updates)
+				err = begin_ref_updates(client, &imsg);
+			else if (do_ref_update)
+				err = update_ref(client, proc->chroot_path,
+				    &imsg);
+			if (err)
+				log_warnx("uid %d: %s", client->euid, err->msg);
+		}
 		imsg_free(&imsg);
 	}
 done: