Reject "-o" when using "-d".

This commit is contained in:
Andrew Wood
2025-09-23 05:45:43 +01:00
parent 05a72bf75e
commit a0a9d682ca
+9
View File
@@ -795,6 +795,15 @@ opts_t opts_parse(unsigned int argc, char **argv)
/*@+mustfreefresh@ */
}
if (NULL != opts->output) {
/*@-mustfreefresh@ *//* see above */
fprintf(stderr, "%s: -o: %s\n", opts->program_name,
_("cannot transfer files when watching file descriptors"));
opts_free(opts);
return NULL;
/*@+mustfreefresh@ */
}
/* Accept additional pid[:fd] arguments. */
while (optind < (int) argc) {
parse_pid = 0;