mirror of
https://github.com/UzixLS/picocom.git
synced 2025-07-19 07:21:18 +03:00
Do not allow --telnet and --noreset / --hangup
This commit is contained in:
@ -1934,6 +1934,12 @@ parse_args(int argc, char *argv[])
|
||||
exit(EXIT_FAILURE);
|
||||
}
|
||||
|
||||
if (opts.telnet && (opts.noreset || opts.hangup)) {
|
||||
fprintf(stderr, "Options --telnet and --noreset / --hangup "
|
||||
"cannot be given together\n");
|
||||
exit(EXIT_FAILURE);
|
||||
}
|
||||
|
||||
/* --exit overrides --exit-after */
|
||||
if ( opts.exit ) opts.exit_after = -1;
|
||||
|
||||
|
Reference in New Issue
Block a user