aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTianjie Xu2018-02-28 12:49:56 -0600
committerGerrit Code Review2018-02-28 12:49:56 -0600
commitac4818d6afe80cb71d19d34cd6c36fd9a04e7b6d (patch)
treef24ac44003f8381db9bb5d25f8daac0850266eb5
parentcc3446a7f7e5b016573e57d0153fc0efa06059c1 (diff)
parentc2420845391bb8b50cb782c5fee95f0fa643e49c (diff)
downloadplatform-bootable-recovery-ac4818d6afe80cb71d19d34cd6c36fd9a04e7b6d.tar.gz
platform-bootable-recovery-ac4818d6afe80cb71d19d34cd6c36fd9a04e7b6d.tar.xz
platform-bootable-recovery-ac4818d6afe80cb71d19d34cd6c36fd9a04e7b6d.zip
Merge "Fix the behavior of undefined commands in BlockImageVerify"
-rw-r--r--updater/blockimg.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/updater/blockimg.cpp b/updater/blockimg.cpp
index feb2aeb2..4f085b20 100644
--- a/updater/blockimg.cpp
+++ b/updater/blockimg.cpp
@@ -1727,9 +1727,11 @@ static Value* PerformBlockImageUpdate(const char* name, State* state,
1727 1727
1728 const Command* cmd = cmd_map[params.cmdname]; 1728 const Command* cmd = cmd_map[params.cmdname];
1729 1729
1730 // Skip the command if we explicitly set the corresponding function pointer to nullptr, e.g.
1731 // "erase" during block_image_verify.
1730 if (cmd->f == nullptr) { 1732 if (cmd->f == nullptr) {
1731 LOG(ERROR) << "failed to find the function for command [" << line << "]"; 1733 LOG(DEBUG) << "skip executing command [" << line << "]";
1732 goto pbiudone; 1734 continue;
1733 } 1735 }
1734 1736
1735 // Skip all commands before the saved last command index when resuming an update. 1737 // Skip all commands before the saved last command index when resuming an update.