summaryrefslogtreecommitdiffstats
path: root/update_verifier/update_verifier_main.cpp
diff options
context:
space:
mode:
authorEthan Yonker <dees_troy@teamw.in>2018-08-24 18:17:36 +0200
committerEthan Yonker <dees_troy@teamw.in>2018-08-24 18:17:39 +0200
commit58f2132bc3954fc704787d477500a209eedb8e29 (patch)
treeeb0f79aacd68724b0c0c091018384ef924380f47 /update_verifier/update_verifier_main.cpp
parentRemove remaining pieces of supersu (diff)
parentSnap for 4745538 from 723056a83f8c8b15af02d9c302862dbb2304ea8c to pi-release (diff)
downloadandroid_bootable_recovery-58f2132bc3954fc704787d477500a209eedb8e29.tar
android_bootable_recovery-58f2132bc3954fc704787d477500a209eedb8e29.tar.gz
android_bootable_recovery-58f2132bc3954fc704787d477500a209eedb8e29.tar.bz2
android_bootable_recovery-58f2132bc3954fc704787d477500a209eedb8e29.tar.lz
android_bootable_recovery-58f2132bc3954fc704787d477500a209eedb8e29.tar.xz
android_bootable_recovery-58f2132bc3954fc704787d477500a209eedb8e29.tar.zst
android_bootable_recovery-58f2132bc3954fc704787d477500a209eedb8e29.zip
Diffstat (limited to 'update_verifier/update_verifier_main.cpp')
-rw-r--r--update_verifier/update_verifier_main.cpp15
1 files changed, 15 insertions, 0 deletions
diff --git a/update_verifier/update_verifier_main.cpp b/update_verifier/update_verifier_main.cpp
index 46e8bbb59..a86203bfb 100644
--- a/update_verifier/update_verifier_main.cpp
+++ b/update_verifier/update_verifier_main.cpp
@@ -16,8 +16,23 @@
// See the comments in update_verifier.cpp.
+#include <string>
+
+#include <android-base/logging.h>
+#include <android-base/properties.h>
+
#include "update_verifier/update_verifier.h"
int main(int argc, char** argv) {
+ std::string s = android::base::GetProperty("ro.boot.slot_suffix", "");
+
+ if (s.empty()) {
+ return 0; // non-A/B update device, so we quit
+ }
+
+ // Set up update_verifier logging to be written to kmsg; because we may not have Logd during
+ // boot time.
+ android::base::InitLogging(argv, &android::base::KernelLogger);
+
return update_verifier(argc, argv);
}