]> mj.ucw.cz Git - nwho.git/commitdiff
Fixup for the previous commit
authorMartin Mares <mj@ucw.cz>
Sun, 4 Nov 2018 14:00:39 +0000 (15:00 +0100)
committerMartin Mares <mj@ucw.cz>
Sun, 4 Nov 2018 14:00:39 +0000 (15:00 +0100)
nwhod.c

diff --git a/nwhod.c b/nwhod.c
index 480fd001f85267270b81b41cd1cc235f9715930a..9407f6fa0334af796649741e361cc4b0e30969a8 100644 (file)
--- a/nwhod.c
+++ b/nwhod.c
@@ -382,8 +382,13 @@ main(int argc, char **argv)
        usage();
       }
 
-  if (optind == argc-1 && argv[optind][0])
-    client(argv[optind]);
+  if (optind == argc-1)
+    {
+      if (argv[optind][0])
+       client(argv[optind]);
+      else
+       server();
+    }
   else if (optind == argc)
     server();
   else