summaryrefslogtreecommitdiff
path: root/libnativeloader/native_loader.cpp
diff options
context:
space:
mode:
authorOrion Hodson <oth@google.com>2019-02-21 17:18:44 +0000
committerOrion Hodson <oth@google.com>2019-02-22 08:55:48 +0000
commit34b126b98b4677fb432c20a76e7592e4d6a53039 (patch)
tree5e81a39ccbc4acf50e4787eb889edc63400027ea /libnativeloader/native_loader.cpp
parent69fc7b628dfb431fcd179eea235976284ad925ac (diff)
Remove dependency on libcutils
libnativeloader is in the Runtime Module, libcutils is not. Dependency was on property_get so moving to libbase equivalent. Bug: b/125323247 Test: m -j100 Change-Id: I295ffa14b475a193a851db89dbb3b4c9cc0183d2
Diffstat (limited to 'libnativeloader/native_loader.cpp')
-rw-r--r--libnativeloader/native_loader.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/libnativeloader/native_loader.cpp b/libnativeloader/native_loader.cpp
index 09998f027..f9c161c6d 100644
--- a/libnativeloader/native_loader.cpp
+++ b/libnativeloader/native_loader.cpp
@@ -21,7 +21,6 @@
#ifdef __ANDROID__
#define LOG_TAG "libnativeloader"
#include "nativeloader/dlext_namespaces.h"
-#include "cutils/properties.h"
#include "log/log.h"
#endif
#include <dirent.h>
@@ -144,9 +143,11 @@ static constexpr const char* kRuntimeApexLibPath = "/apex/com.android.runtime/li
#endif
static bool is_debuggable() {
- char debuggable[PROP_VALUE_MAX];
- property_get("ro.debuggable", debuggable, "0");
- return std::string(debuggable) == "1";
+ bool debuggable = false;
+#ifdef __BIONIC__
+ debuggable = android::base::GetBoolProperty("ro.debuggable", false);
+#endif
+ return debuggable;
}
static std::string vndk_version_str() {