int opt_flags = -1;
int opt_timeout = 0;
const char *opt_target_workgroup = NULL;
-static int opt_machine_pass = 0;
+int opt_machine_pass = 0;
BOOL opt_have_ip = False;
struct in_addr opt_dest_ip;
{
NTSTATUS nt_status;
- if (!opt_password) {
+ if (!opt_password && !opt_machine_pass) {
char *pass = getpass("Password:");
if (pass) {
opt_password = strdup(pass);
extern int opt_long_list_entries;
extern int opt_reboot;
extern int opt_force;
+extern int opt_machine_pass;
extern int opt_timeout;
extern const char *opt_host;
extern const char *opt_user_name;
}
retry:
- if (!opt_password && need_password) {
+ if (!opt_password && need_password && !opt_machine_pass) {
char *prompt;
asprintf(&prompt,"%s password: ", opt_user_name);
opt_password = getpass(prompt);