We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 86bc0ae commit 943aa99Copy full SHA for 943aa99
google-http-client/src/main/java/com/google/api/client/http/javanet/NetHttpRequest.java
@@ -63,7 +63,7 @@ public LowLevelHttpResponse execute() throws IOException {
63
}
64
long contentLength = getContentLength();
65
if (contentLength >= 0) {
66
- addHeader("Content-Length", Long.toString(contentLength));
+ connection.setRequestProperty("Content-Length", Long.toString(contentLength));
67
68
String requestMethod = connection.getRequestMethod();
69
if ("POST".equals(requestMethod) || "PUT".equals(requestMethod)) {
0 commit comments