const char *opt_container = NULL;
int opt_flags = -1;
int opt_timeout = 0;
+int opt_request_timeout = 0;
const char *opt_target_workgroup = NULL;
int opt_machine_pass = 0;
int opt_localgroup = False;
d_fprintf(stderr, "Connection failed: %s\n",
nt_errstr(nt_status));
cli = NULL;
+ } else if (opt_request_timeout) {
+ cli_set_timeout(cli, opt_request_timeout * 1000);
}
done:
{"force", 'f', POPT_ARG_NONE, &opt_force},
{"stdin", 'i', POPT_ARG_NONE, &opt_stdin},
{"timeout", 't', POPT_ARG_INT, &opt_timeout},
+ {"request-timeout",0,POPT_ARG_INT, &opt_request_timeout},
{"machine-pass",'P', POPT_ARG_NONE, &opt_machine_pass},
{"myworkgroup", 'W', POPT_ARG_STRING, &opt_workgroup},
{"verbose", 'v', POPT_ARG_NONE, &opt_verbose},
extern int opt_force;
extern int opt_machine_pass;
extern int opt_timeout;
+extern int opt_request_timeout;
extern const char *opt_host;
extern const char *opt_user_name;
extern const char *opt_password;
d_printf("\t-l or --long\t\t\tDisplay full information\n");
d_printf("\t-V or --version\t\t\tPrint samba version information\n");
d_printf("\t-P or --machine-pass\t\tAuthenticate as machine account\n");
- d_printf("\t-e or --encrypt\t\tEncrypt SMB transport (UNIX extended servers only)\n");
+ d_printf("\t-e or --encrypt\t\t\tEncrypt SMB transport (UNIX extended servers only)\n");
+ d_printf("\t--request-timeout\t\tThe timeout for smb and rpc requests in seconds\n");
return -1;
}