Commit c56af3fdaec8a156f341675b6781966a74456c9f

Stefan Sperling 2020-02-17T20:24:04

add missing error check in gw_output_blob_buf()

1
2
3
4
5
6
7
8
9
10
11
12
13
diff --git a/gotweb/gotweb.c b/gotweb/gotweb.c
index 6850d90..879b0a9 100644
--- a/gotweb/gotweb.c
+++ b/gotweb/gotweb.c
@@ -3682,6 +3682,8 @@ gw_output_blob_buf(struct gw_trans *gw_trans)
 				goto done;
 		}
 		kerr = khttp_write(gw_trans->gw_req, buf, len - hdrlen);
+		if (kerr != KCGI_OK)
+			goto done;
 		hdrlen = 0;
 	} while (len != 0);
 done: