summaryrefslogtreecommitdiff
path: root/methods/http.cc
diff options
context:
space:
mode:
authorDavid Kalnischkies <david@kalnischkies.de>2016-07-30 09:57:50 +0200
committerDavid Kalnischkies <david@kalnischkies.de>2016-07-30 10:14:47 +0200
commit7303e11ff28f920a6277c159aa46f80c007350bb (patch)
treee7f368b106c71af3babd141db55e359f25e1b632 /methods/http.cc
parentb60c8a89c281f2bb945d426d2215cbf8f5760738 (diff)
prevent C++ locale number formatting in text APIs (try 2)
Followup of b58e2c7c56b1416a343e81f9f80cb1f02c128e25. Still a regression of sorts of 8b79c94af7f7cf2e5e5342294bc6e5a908cacabf. Closes: 832044
Diffstat (limited to 'methods/http.cc')
-rw-r--r--methods/http.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/methods/http.cc b/methods/http.cc
index 64cfe0f85..9fcc80103 100644
--- a/methods/http.cc
+++ b/methods/http.cc
@@ -738,7 +738,7 @@ void HttpMethod::SendReq(FetchItem *Itm)
// Check for a partial file and send if-queries accordingly
struct stat SBuf;
if (stat(Itm->DestFile.c_str(),&SBuf) >= 0 && SBuf.st_size > 0)
- Req << "Range: bytes=" << SBuf.st_size << "-\r\n"
+ Req << "Range: bytes=" << std::to_string(SBuf.st_size) << "-\r\n"
<< "If-Range: " << TimeRFC1123(SBuf.st_mtime, false) << "\r\n";
else if (Itm->LastModified != 0)
Req << "If-Modified-Since: " << TimeRFC1123(Itm->LastModified, false).c_str() << "\r\n";