aboutsummaryrefslogtreecommitdiffstats
path: root/android/help.c
diff options
context:
space:
mode:
authorOt ten Thije <ottenthije@google.com>2010-10-18 13:37:37 +0100
committerOt ten Thije <ottenthije@google.com>2010-10-28 13:47:54 +0100
commitae835acc2d1a8b4aaeb599add9cfc02ea5789eaf (patch)
treeaff76c935e32ce7bf6a0ae26150fa1ffd56e8faa /android/help.c
parent2ff39a367738422c0ca1313cac8ff380e1fdd498 (diff)
downloadexternal_qemu-ae835acc2d1a8b4aaeb599add9cfc02ea5789eaf.zip
external_qemu-ae835acc2d1a8b4aaeb599add9cfc02ea5789eaf.tar.gz
external_qemu-ae835acc2d1a8b4aaeb599add9cfc02ea5789eaf.tar.bz2
Add command line flag to show list of snapshots.
This patch introduces the flag '-snapshot-list', which causes the emulator to output a table of snapshots in the currently mounted snapshot storage file. The snapshot file is accessed with a very simple driver for the Qcow2 file system, independent of Qemu's block driver framework. This way, the flag is available in the emulator-ui builds as well. Using Qemu's framework would have resulted in adding a lot of Qemu dependencies to the UI build, which we are explicitly trying to avoid. Change-Id: I059b9ac53e2f8e051757a5c637761eccf8ea17cb
Diffstat (limited to 'android/help.c')
-rw-r--r--android/help.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/android/help.c b/android/help.c
index 17e7a90..f589b3e 100644
--- a/android/help.c
+++ b/android/help.c
@@ -700,6 +700,21 @@ help_no_snapshot(stralloc_t* out)
);
}
+static void
+help_snapshot_list(stralloc_t* out)
+{
+ PRINTF(
+ " This prints a table of snapshots that are stored in the snapshot storage\n"
+ " file that the emulator was started with, then exits. Values from the 'ID'\n"
+ " and 'TAG' columns can be used as arguments for the '-snapshot' parameter.\n\n"
+
+ " If '-snapstorage <file>' was specified as well, this command prints a "
+ " table of the snapshots stored in <file>.\n\n"
+
+ " See '-help-snapshot' for more information on snapshots.\n\n"
+ );
+}
+
#endif
static void