25 lines
1014 B
Diff
25 lines
1014 B
Diff
|
Index: xen-3.3.0-testing/tools/ioemu-remote/xenstore.c
|
||
|
===================================================================
|
||
|
--- xen-3.3.0-testing.orig/tools/ioemu-remote/xenstore.c
|
||
|
+++ xen-3.3.0-testing/tools/ioemu-remote/xenstore.c
|
||
|
@@ -652,6 +652,19 @@ static void xenstore_process_dm_command_
|
||
|
}
|
||
|
|
||
|
snapshot_name = xs_read(xsh, XBT_NULL, path, &len);
|
||
|
+ } else if (!strncmp(command, "snapshot-delete", len)) {
|
||
|
+
|
||
|
+ if (pasprintf(&path,
|
||
|
+ "/local/domain/0/device-model/%u/parameter", domid) == -1) {
|
||
|
+ fprintf(logfile, "out of memory reading dm command parameter\n");
|
||
|
+ goto out;
|
||
|
+ }
|
||
|
+ par = xs_read(xsh, XBT_NULL, path, &len);
|
||
|
+ if (!par)
|
||
|
+ goto out;
|
||
|
+ // TODO Error handling
|
||
|
+ do_delvm(par);
|
||
|
+ xenstore_record_dm_state("snapshot-deleted");
|
||
|
} else if (!strncmp(command, "continue", len)) {
|
||
|
fprintf(logfile, "dm-command: continue after state save\n");
|
||
|
xen_pause_requested = 0;
|