]> git.sur5r.net Git - ngadmin/blobdiff - cli/com_quit.c
Let commands handle themselves absence of arguments
[ngadmin] / cli / com_quit.c
index 96cb0690099f2730d56d15ee1d75a5c8f5b30245..8a78fe16ec09e627d20bce9cdf149fbb7c5cf084 100644 (file)
@@ -2,9 +2,14 @@
 #include "commands.h"
 
 
-bool do_quit (int nb UNUSED, const char **com UNUSED, struct ngadmin *nga UNUSED)
+bool do_quit (int argc, const char **argv UNUSED, struct ngadmin *nga UNUSED)
 {
-       cont = 0;
+       if (argc > 0) {
+               printf("this command takes no argument\n");
+               return false;
+       }
+       
+       main_loop_continue = 0;
        
        return true;
 }