]>
Commit | Line | Data |
---|---|---|
f47a9db4 TM |
1 | From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 |
2 | From: Tim Marx <t.marx@proxmox.com> | |
3 | Date: Wed, 22 Jan 2020 16:22:14 +0100 | |
4 | Subject: [PATCH] PVE: fix hmp info backup cmd for not initialized | |
5 | backup_state.backup_mutex | |
6 | ||
7 | Signed-off-by: Tim Marx <t.marx@proxmox.com> | |
8 | --- | |
9 | monitor/hmp-cmds.c | 6 ++++++ | |
10 | 1 file changed, 6 insertions(+) | |
11 | ||
12 | diff --git a/monitor/hmp-cmds.c b/monitor/hmp-cmds.c | |
13 | index bc9ca346f7..fb820410de 100644 | |
14 | --- a/monitor/hmp-cmds.c | |
15 | +++ b/monitor/hmp-cmds.c | |
16 | @@ -201,6 +201,12 @@ void hmp_info_backup(Monitor *mon, const QDict *qdict) | |
17 | BackupStatus *info; | |
18 | ||
19 | info = qmp_query_backup(NULL); | |
20 | + | |
21 | + if (!info) { | |
2c67b152 TL |
22 | + monitor_printf(mon, "Backup status: not initialized\n"); |
23 | + return; | |
f47a9db4 TM |
24 | + } |
25 | + | |
26 | if (info->has_status) { | |
27 | if (info->has_errmsg) { | |
28 | monitor_printf(mon, "Backup status: %s - %s\n", | |
29 | -- | |
30 | 2.20.1 | |
31 |