diff options
author | David Kalnischkies <david@kalnischkies.de> | 2016-05-28 13:22:38 +0200 |
---|---|---|
committer | David Kalnischkies <david@kalnischkies.de> | 2016-05-28 18:12:02 +0200 |
commit | 8b79c94af7f7cf2e5e5342294bc6e5a908cacabf (patch) | |
tree | b5e7c254f6a4aa96203aee262cf5fb13ded87fbb /methods/ftp.cc | |
parent | eceb219c2a64f3f81421c3c6587380b6ae81a530 (diff) |
use std::locale::global instead of setlocale
We use a wild mixture of C and C++ ways of generating output, so having
a consistent world-view in both styles sounds like a good idea and
should help in preventing regressions.
Diffstat (limited to 'methods/ftp.cc')
-rw-r--r-- | methods/ftp.cc | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/methods/ftp.cc b/methods/ftp.cc index a8bc95938..6a886dd19 100644 --- a/methods/ftp.cc +++ b/methods/ftp.cc @@ -18,7 +18,6 @@ #include <config.h> #include <apt-pkg/fileutl.h> -#include <apt-pkg/acquire-method.h> #include <apt-pkg/error.h> #include <apt-pkg/hashes.h> #include <apt-pkg/netrc.h> @@ -1115,9 +1114,7 @@ bool FtpMethod::Fetch(FetchItem *Itm) /*}}}*/ int main(int, const char *argv[]) -{ - setlocale(LC_ALL, ""); - +{ /* See if we should be come the http client - we do this for http proxy urls */ if (getenv("ftp_proxy") != 0) @@ -1140,8 +1137,5 @@ int main(int, const char *argv[]) exit(100); } } - - FtpMethod Mth; - - return Mth.Run(); + return FtpMethod().Run(); } |