Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 60ecf22

Browse files
committed
Disabling keep-alive to prevent broken pipe errors
1 parent 313ece8 commit 60ecf22

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/com/alexbbb/uploadservice/UploadService.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -244,7 +244,7 @@ private byte[] getTrailerBytes(final String boundary) throws UnsupportedEncoding
244244
conn.setUseCaches(false);
245245
conn.setChunkedStreamingMode(0);
246246
conn.setRequestMethod(method);
247-
conn.setRequestProperty("Connection", "Keep-Alive");
247+
conn.setRequestProperty("Connection", "close");
248248
conn.setRequestProperty("ENCTYPE", "multipart/form-data");
249249
conn.setRequestProperty("Content-Type", "multipart/form-data; boundary=" + boundary);
250250

0 commit comments

Comments
 (0)