Merge "Add explicit sync call to ion library" into jb-mr1-dev
diff --git a/debuggerd/tombstone.c b/debuggerd/tombstone.c
index 012337b..592f4f2 100644
--- a/debuggerd/tombstone.c
+++ b/debuggerd/tombstone.c
@@ -128,6 +128,15 @@
return "?";
}
+static void dump_revision_info(log_t* log)
+{
+ char revision[PROPERTY_VALUE_MAX];
+
+ property_get("ro.revision", revision, "unknown");
+
+ _LOG(log, false, "Revision: '%s'\n", revision);
+}
+
static void dump_build_info(log_t* log)
{
char fingerprint[PROPERTY_VALUE_MAX];
@@ -599,6 +608,7 @@
_LOG(log, false,
"*** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***\n");
dump_build_info(log);
+ dump_revision_info(log);
dump_thread_info(log, pid, tid, true);
if(signal) {
dump_fault_addr(log, tid, signal);
diff --git a/init/property_service.c b/init/property_service.c
index c378aeb..f58e07d 100755
--- a/init/property_service.c
+++ b/init/property_service.c
@@ -582,6 +582,16 @@
return property_area_inited;
}
+static void load_override_properties() {
+#ifdef ALLOW_LOCAL_PROP_OVERRIDE
+ const char *debuggable = property_get("ro.debuggable");
+ if (debuggable && (strcmp(debuggable, "1") == 0)) {
+ load_properties_from_file(PROP_PATH_LOCAL_OVERRIDE);
+ }
+#endif /* ALLOW_LOCAL_PROP_OVERRIDE */
+}
+
+
/* When booting an encrypted system, /data is not mounted when the
* property service is started, so any properties stored there are
* not loaded. Vold triggers init to load these properties once it
@@ -589,9 +599,7 @@
*/
void load_persist_props(void)
{
-#ifdef ALLOW_LOCAL_PROP_OVERRIDE
- load_properties_from_file(PROP_PATH_LOCAL_OVERRIDE);
-#endif /* ALLOW_LOCAL_PROP_OVERRIDE */
+ load_override_properties();
/* Read persistent properties after all default values have been loaded. */
load_persistent_properties();
}
@@ -602,9 +610,7 @@
load_properties_from_file(PROP_PATH_SYSTEM_BUILD);
load_properties_from_file(PROP_PATH_SYSTEM_DEFAULT);
-#ifdef ALLOW_LOCAL_PROP_OVERRIDE
- load_properties_from_file(PROP_PATH_LOCAL_OVERRIDE);
-#endif /* ALLOW_LOCAL_PROP_OVERRIDE */
+ load_override_properties();
/* Read persistent properties after all default values have been loaded. */
load_persistent_properties();