summaryrefslogtreecommitdiff
path: root/apt-private
diff options
context:
space:
mode:
authorDavid Kalnischkies <david@kalnischkies.de>2016-05-28 13:22:38 +0200
committerDavid Kalnischkies <david@kalnischkies.de>2016-05-28 18:12:02 +0200
commit8b79c94af7f7cf2e5e5342294bc6e5a908cacabf (patch)
treeb5e7c254f6a4aa96203aee262cf5fb13ded87fbb /apt-private
parenteceb219c2a64f3f81421c3c6587380b6ae81a530 (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 'apt-private')
-rw-r--r--apt-private/private-main.cc4
1 files changed, 3 insertions, 1 deletions
diff --git a/apt-private/private-main.cc b/apt-private/private-main.cc
index 9eb306834..0a9f4713f 100644
--- a/apt-private/private-main.cc
+++ b/apt-private/private-main.cc
@@ -7,6 +7,8 @@
#include <apt-private/private-main.h>
#include <iostream>
+#include <locale>
+
#include <string.h>
#include <unistd.h>
#include <signal.h>
@@ -16,7 +18,7 @@
void InitLocale() /*{{{*/
{
- setlocale(LC_ALL,"");
+ std::locale::global(std::locale(""));
textdomain(PACKAGE);
}
/*}}}*/