]> git.saurik.com Git - apt.git/blobdiff - cmdline/apt-cdrom.cc
replace "which" with "command -v" for portability
[apt.git] / cmdline / apt-cdrom.cc
index 4a24f198c3f52316b7dd5fa3a1fe4abac91de671..ba01a4c7475aa0664f44b2a275dfeffd86ad06f1 100644 (file)
@@ -203,7 +203,7 @@ static bool DoIdent(CommandLine &)
    return AddOrIdent(false);
 }
                                                                        /*}}}*/
-bool ShowHelp(CommandLine &)                                           /*{{{*/
+static bool ShowHelp(CommandLine &)                                    /*{{{*/
 {
    std::cout <<
       _("Usage: apt-cdrom [options] command\n"
@@ -214,7 +214,7 @@ bool ShowHelp(CommandLine &)                                                /*{{{*/
    return true;
 }
                                                                        /*}}}*/
-std::vector<aptDispatchWithHelp> GetCommands()                         /*{{{*/
+static std::vector<aptDispatchWithHelp> GetCommands()                  /*{{{*/
 {
    return {
       {"add", &DoAdd, "Add a CDROM"},
@@ -229,7 +229,7 @@ int main(int argc,const char *argv[])                                       /*{{{*/
 
    // Parse the command line and initialize the package library
    CommandLine CmdL;
-   auto const Cmds = ParseCommandLine(CmdL, APT_CMD::APT_CDROM, &_config, &_system, argc, argv);
+   auto const Cmds = ParseCommandLine(CmdL, APT_CMD::APT_CDROM, &_config, &_system, argc, argv, &ShowHelp, &GetCommands);
 
    InitOutput();