Commit d81cc9b5 authored by Martin Blix Grydeland's avatar Martin Blix Grydeland

Always exit if no socket could be connected

parent 7077261e
......@@ -349,16 +349,14 @@ main(int argc, char * const *argv)
usage();
}
sock = n_arg_sock(n_arg);
if (sock < 0)
exit(2);
} else if (T_arg == NULL) {
sock = n_arg_sock("");
if (sock < 0)
exit(2);
} else {
assert(T_arg != NULL);
sock = cli_sock(T_arg, S_arg);
}
if (sock < 0)
exit(2);
if (argc > 0)
do_args(sock, argc, argv);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment