Revision 2895e075
b/monitor.c | ||
---|---|---|
815 | 815 |
monitor_read_bdrv_key_start(mon, bs, NULL, NULL); |
816 | 816 |
} |
817 | 817 |
|
818 |
static void change_vnc_password_cb(Monitor *mon, const char *password, |
|
819 |
void *opaque) |
|
818 |
static void change_vnc_password(Monitor *mon, const char *password) |
|
820 | 819 |
{ |
821 | 820 |
if (vnc_display_password(NULL, password) < 0) |
822 | 821 |
monitor_printf(mon, "could not set VNC server password\n"); |
823 | 822 |
|
823 |
} |
|
824 |
|
|
825 |
static void change_vnc_password_cb(Monitor *mon, const char *password, |
|
826 |
void *opaque) |
|
827 |
{ |
|
828 |
change_vnc_password(mon, password); |
|
824 | 829 |
monitor_read_command(mon, 1); |
825 | 830 |
} |
826 | 831 |
|
... | ... | |
832 | 837 |
char password[9]; |
833 | 838 |
strncpy(password, arg, sizeof(password)); |
834 | 839 |
password[sizeof(password) - 1] = '\0'; |
835 |
change_vnc_password_cb(mon, password, NULL);
|
|
840 |
change_vnc_password(mon, password);
|
|
836 | 841 |
} else { |
837 | 842 |
monitor_read_password(mon, change_vnc_password_cb, NULL); |
838 | 843 |
} |
Also available in: Unified diff