From b58e2c7c56b1416a343e81f9f80cb1f02c128e25 Mon Sep 17 00:00:00 2001 From: David Kalnischkies Date: Fri, 27 May 2016 18:10:39 +0200 Subject: prevent C++ locale number formatting in text APIs Setting the C++ locale via std::locale::global(std::locale("")); which would otherwise default to the default C locale (aka: unaffected by setlocale) effects the formatting of numeric types in IO streams, which for output for humans is perfectly sensible, but breaks our many text interfaces used and parsed by us and others without expecting the numbers to be formatted. Closes: #825396 --- methods/server.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'methods/server.cc') diff --git a/methods/server.cc b/methods/server.cc index b323ef4f3..d606f26aa 100644 --- a/methods/server.cc +++ b/methods/server.cc @@ -130,7 +130,7 @@ bool ServerState::HeaderLine(string Line) { Code[0] = '\0'; if (Owner != NULL && Owner->Debug == true) - clog << "HTTP server doesn't give Reason-Phrase for " << Result << std::endl; + clog << "HTTP server doesn't give Reason-Phrase for " << std::to_string(Result) << std::endl; } else if (elements != 4) return _error->Error(_("The HTTP server sent an invalid reply header")); -- cgit v1.2.3