summaryrefslogtreecommitdiffstats
path: root/recovery.cpp
diff options
context:
space:
mode:
authorTianjie Xu <xunchang@google.com>2016-04-29 03:06:26 +0200
committerTianjie Xu <xunchang@google.com>2016-04-29 21:19:43 +0200
commit35926c4b89f9dc51f3e55ef03a61e4da6dcb34be (patch)
tree40b27d4d1fcd410295d64bc7a33002adb230ac6e /recovery.cpp
parentMerge "Improve the layout-related comments." into nyc-dev (diff)
downloadandroid_bootable_recovery-35926c4b89f9dc51f3e55ef03a61e4da6dcb34be.tar
android_bootable_recovery-35926c4b89f9dc51f3e55ef03a61e4da6dcb34be.tar.gz
android_bootable_recovery-35926c4b89f9dc51f3e55ef03a61e4da6dcb34be.tar.bz2
android_bootable_recovery-35926c4b89f9dc51f3e55ef03a61e4da6dcb34be.tar.lz
android_bootable_recovery-35926c4b89f9dc51f3e55ef03a61e4da6dcb34be.tar.xz
android_bootable_recovery-35926c4b89f9dc51f3e55ef03a61e4da6dcb34be.tar.zst
android_bootable_recovery-35926c4b89f9dc51f3e55ef03a61e4da6dcb34be.zip
Diffstat (limited to '')
-rw-r--r--recovery.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/recovery.cpp b/recovery.cpp
index dbdc1fbd6..4b71881f7 100644
--- a/recovery.cpp
+++ b/recovery.cpp
@@ -75,6 +75,7 @@ static const struct option OPTIONS[] = {
{ "stages", required_argument, NULL, 'g' },
{ "shutdown_after", no_argument, NULL, 'p' },
{ "reason", required_argument, NULL, 'r' },
+ { "security", no_argument, NULL, 'e'},
{ NULL, 0, NULL, 0 },
};
@@ -1344,6 +1345,7 @@ int main(int argc, char **argv) {
bool just_exit = false;
bool shutdown_after = false;
int retry_count = 0;
+ bool security_update = false;
int arg;
while ((arg = getopt_long(argc, argv, "", OPTIONS, NULL)) != -1) {
@@ -1368,6 +1370,7 @@ int main(int argc, char **argv) {
}
case 'p': shutdown_after = true; break;
case 'r': reason = optarg; break;
+ case 'e': security_update = true; break;
case '?':
LOGE("Invalid command argument\n");
continue;
@@ -1387,6 +1390,9 @@ int main(int argc, char **argv) {
ui->SetLocale(locale);
ui->Init();
+ // Set background string to "installing security update" for security update,
+ // otherwise set it to "installing system update".
+ ui->SetSystemUpdateText(security_update);
int st_cur, st_max;
if (stage != NULL && sscanf(stage, "%d/%d", &st_cur, &st_max) == 2) {