summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJerry Zhang <zhangjerry@google.com>2018-05-17 23:44:41 +0200
committerandroid-build-merger <android-build-merger@google.com>2018-05-17 23:44:41 +0200
commit25d31c9f9cfcf5a868e0280db6221e64517b8af1 (patch)
tree14fadf8929d56faab3e82f6c82f2702d3557ffc2
parentMerge "updater_sample: add switch slot demo" (diff)
parentMerge "recovery: Reset optind to 1 after getopt" (diff)
downloadandroid_bootable_recovery-25d31c9f9cfcf5a868e0280db6221e64517b8af1.tar
android_bootable_recovery-25d31c9f9cfcf5a868e0280db6221e64517b8af1.tar.gz
android_bootable_recovery-25d31c9f9cfcf5a868e0280db6221e64517b8af1.tar.bz2
android_bootable_recovery-25d31c9f9cfcf5a868e0280db6221e64517b8af1.tar.lz
android_bootable_recovery-25d31c9f9cfcf5a868e0280db6221e64517b8af1.tar.xz
android_bootable_recovery-25d31c9f9cfcf5a868e0280db6221e64517b8af1.tar.zst
android_bootable_recovery-25d31c9f9cfcf5a868e0280db6221e64517b8af1.zip
-rw-r--r--recovery.cpp1
-rw-r--r--recovery_main.cpp1
2 files changed, 2 insertions, 0 deletions
diff --git a/recovery.cpp b/recovery.cpp
index b1a2900fd..21f633011 100644
--- a/recovery.cpp
+++ b/recovery.cpp
@@ -1049,6 +1049,7 @@ Device::BuiltinAction start_recovery(Device* device, const std::vector<std::stri
continue;
}
}
+ optind = 1;
printf("stage is [%s]\n", stage.c_str());
printf("reason is [%s]\n", reason);
diff --git a/recovery_main.cpp b/recovery_main.cpp
index e21c782d0..5e82c6c1a 100644
--- a/recovery_main.cpp
+++ b/recovery_main.cpp
@@ -317,6 +317,7 @@ int main(int argc, char** argv) {
}
}
}
+ optind = 1;
if (locale.empty()) {
if (has_cache) {