mirror of
https://github.com/Tiiffi/mcrcon.git
synced 2025-10-28 03:41:07 -04:00
Exit with appropriate return code if password is not provided, fixes #87
This commit is contained in:
2
mcrcon.c
2
mcrcon.c
@ -209,7 +209,7 @@ int main(int argc, char *argv[])
|
|||||||
|
|
||||||
if (pass == NULL) {
|
if (pass == NULL) {
|
||||||
puts("You must give password (-p password).\nTry 'mcrcon -h' or 'man mcrcon' for help.");
|
puts("You must give password (-p password).\nTry 'mcrcon -h' or 'man mcrcon' for help.");
|
||||||
return 0;
|
exit(EXIT_FAILURE);
|
||||||
}
|
}
|
||||||
|
|
||||||
if(optind == argc && terminal_mode == 0)
|
if(optind == argc && terminal_mode == 0)
|
||||||
|
|||||||
Reference in New Issue
Block a user