summaryrefslogtreecommitdiff
path: root/fastboot/fastboot.cpp
diff options
context:
space:
mode:
authorDavid Anderson <dvander@google.com>2019-11-19 00:49:44 +0000
committerGerrit Code Review <noreply-gerritcodereview@google.com>2019-11-19 00:49:44 +0000
commitbf55a76fd9ce15b288d8cfa5425fb889bd069d51 (patch)
treee0d004d0184c2839c9f7b7bb65a5a7d09e9c322d /fastboot/fastboot.cpp
parent7d16aedc47552bbb67563ef6754a77c88b5821ea (diff)
parent220ddb1f0fb9d0e47f7c812c93da174ea3a8c037 (diff)
Merge "fastbootd: Disallow certain operations during snapshot updates."
Diffstat (limited to 'fastboot/fastboot.cpp')
-rw-r--r--fastboot/fastboot.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/fastboot/fastboot.cpp b/fastboot/fastboot.cpp
index 7ce7c7c0e..cbd42b17e 100644
--- a/fastboot/fastboot.cpp
+++ b/fastboot/fastboot.cpp
@@ -399,6 +399,9 @@ static int show_help() {
" snapshot-update cancel On devices that support snapshot-based updates, cancel\n"
" an in-progress update. This may make the device\n"
" unbootable until it is reflashed.\n"
+ " snapshot-update merge On devices that support snapshot-based updates, finish\n"
+ " an in-progress update if it is in the \"merging\"\n"
+ " phase.\n"
"\n"
"boot image:\n"
" boot KERNEL [RAMDISK [SECOND]]\n"
@@ -2089,8 +2092,8 @@ int FastBootTool::Main(int argc, char* argv[]) {
if (!args.empty()) {
arg = next_arg(&args);
}
- if (!arg.empty() && arg != "cancel") {
- syntax_error("expected: snapshot-update [cancel]");
+ if (!arg.empty() && (arg != "cancel" && arg != "merge")) {
+ syntax_error("expected: snapshot-update [cancel|merge]");
}
fb->SnapshotUpdateCommand(arg);
} else {