summaryrefslogtreecommitdiffstats
path: root/updater/updater.cpp
diff options
context:
space:
mode:
authorTianjie Xu <xunchang@google.com>2016-03-10 22:27:26 +0100
committerAndroid (Google) Code Review <android-gerrit@google.com>2016-03-10 22:27:26 +0100
commitd345de66efb919e8c0d09ee5b4d8ae0d443d6c94 (patch)
tree33e073f4f17960b19336a03fb15e1a40141cb0a2 /updater/updater.cpp
parentRevert "recovery: More refactoring of WearUI" (diff)
parentReboot and retry on I/O errors (diff)
downloadandroid_bootable_recovery-d345de66efb919e8c0d09ee5b4d8ae0d443d6c94.tar
android_bootable_recovery-d345de66efb919e8c0d09ee5b4d8ae0d443d6c94.tar.gz
android_bootable_recovery-d345de66efb919e8c0d09ee5b4d8ae0d443d6c94.tar.bz2
android_bootable_recovery-d345de66efb919e8c0d09ee5b4d8ae0d443d6c94.tar.lz
android_bootable_recovery-d345de66efb919e8c0d09ee5b4d8ae0d443d6c94.tar.xz
android_bootable_recovery-d345de66efb919e8c0d09ee5b4d8ae0d443d6c94.tar.zst
android_bootable_recovery-d345de66efb919e8c0d09ee5b4d8ae0d443d6c94.zip
Diffstat (limited to '')
-rw-r--r--updater/updater.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/updater/updater.cpp b/updater/updater.cpp
index 0f22e6d04..ddc01e125 100644
--- a/updater/updater.cpp
+++ b/updater/updater.cpp
@@ -35,6 +35,8 @@
// (Note it's "updateR-script", not the older "update-script".)
#define SCRIPT_NAME "META-INF/com/google/android/updater-script"
+extern bool have_eio_error;
+
struct selabel_handle *sehandle;
int main(int argc, char** argv) {
@@ -139,6 +141,11 @@ int main(int argc, char** argv) {
state.errmsg = NULL;
char* result = Evaluate(&state, root);
+
+ if (have_eio_error) {
+ fprintf(cmd_pipe, "retry_update\n");
+ }
+
if (result == NULL) {
if (state.errmsg == NULL) {
printf("script aborted (no error message)\n");