From b88c792f0ed2239a98cb190298e63ef52af026d1 Mon Sep 17 00:00:00 2001 From: "Unknown W. Brackets" Date: Tue, 25 Nov 2014 08:37:59 -0800 Subject: [PATCH] Actually use httpVersion_ and userAgent_. --- net/http_client.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/net/http_client.cpp b/net/http_client.cpp index 081958b00b..84879441d0 100644 --- a/net/http_client.cpp +++ b/net/http_client.cpp @@ -220,14 +220,14 @@ int Client::SendRequest(const char *method, const char *resource, const char *ot Buffer buffer; const char *tpl = - "%s %s HTTP/1.1\r\n" + "%s %s HTTP/%s\r\n" "Host: %s\r\n" - "User-Agent: " USERAGENT "\r\n" + "User-Agent: %s\r\n" "Connection: close\r\n" "%s" "\r\n"; - buffer.Printf(tpl, method, resource, host_.c_str(), otherHeaders ? otherHeaders : ""); + buffer.Printf(tpl, method, resource, httpVersion_, host_.c_str(), userAgent_, otherHeaders ? otherHeaders : ""); bool flushed = buffer.FlushSocket(sock()); if (!flushed) { return -1; // TODO error code.