Commit Diff


commit - f7eb3370fd07878c7c3a6f1470243c791f38f8a9
commit + f3dfebfc3bdd798342b4e7bde241e613af75efd8
blob - 6664a0be413a6c6e1b9a90d98cea4891ccaf46c9
blob + 7239625916f46e43ce48da2daf7a77a820f0355b
--- lib/serve.c
+++ lib/serve.c
@@ -1373,7 +1373,7 @@ serve_write(int infd, int outfd, int gotd_sock, const 
 		buf[0] = '\0';
 		err = got_pkt_readpkt(&n, infd, buf, sizeof(buf), chattygot);
 		if (err)
-			break;
+			goto done;
 		if (n == 0) {
 			if (curstate != STATE_EXPECT_MORE_REF_UPDATES) {
 				err = got_error_msg(GOT_ERR_BAD_PACKET,