]> git.saurik.com Git - apt.git/blobdiff - cmdline/apt-sortpkgs.cc
Use C locale instead of C.UTF-8 for protocol strings
[apt.git] / cmdline / apt-sortpkgs.cc
index 7e3301a052047a398d894c0775333e0a2417d884..cf19b84ec4f1f89d140bf0903ae6700653e64be6 100644 (file)
@@ -29,6 +29,7 @@
 #include <vector>
 #include <algorithm>
 #include <stdio.h>
+#include <unistd.h>
 #include <iostream>
 #include <string>
 #include <memory>
@@ -132,7 +133,7 @@ static bool DoIt(string InFile)
    return true;
 }
                                                                        /*}}}*/
-bool ShowHelp(CommandLine &)                                           /*{{{*/
+static bool ShowHelp(CommandLine &)                                    /*{{{*/
 {
    std::cout <<
     _("Usage: apt-sortpkgs [options] file1 [file2 ...]\n"
@@ -143,7 +144,7 @@ bool ShowHelp(CommandLine &)                                                /*{{{*/
    return true;
 }
                                                                        /*}}}*/
-std::vector<aptDispatchWithHelp> GetCommands()                         /*{{{*/
+static std::vector<aptDispatchWithHelp> GetCommands()                  /*{{{*/
 {
    return {
       {nullptr, nullptr, nullptr}
@@ -152,8 +153,6 @@ std::vector<aptDispatchWithHelp> GetCommands()                              /*{{{*/
                                                                        /*}}}*/
 int main(int argc,const char *argv[])                                  /*{{{*/
 {
-   InitLocale();
-
    CommandLine CmdL;
    ParseCommandLine(CmdL, APT_CMD::APT_SORTPKG, &_config, &_system, argc, argv, &ShowHelp, &GetCommands);