Handle errors from getopt

master
C. McEnroe 2020-02-05 22:51:45 -05:00
parent 27eaddb6b9
commit 839cc362a8
1 changed files with 1 additions and 0 deletions

1
chat.c
View File

@ -97,6 +97,7 @@ int main(int argc, char *argv[]) {
break; case 'u': user = optarg;
break; case 'v': self.debug = true;
break; case 'w': pass = optarg;
break; default: return EX_USAGE;
}
}
if (!host) errx(EX_USAGE, "host required");