diff options
author | Tom Cherry <tomcherry@google.com> | 2017-12-13 02:48:23 -0800 |
---|---|---|
committer | Tom Cherry <tomcherry@google.com> | 2017-12-13 02:48:23 -0800 |
commit | e149f3c1d7b6848af6a27e4089d5f0c915e1437d (patch) | |
tree | c591f2e001fa34f2af240f251c5319f77455a18f /libc/system_properties/system_properties.cpp | |
parent | e6e8f6ee77ac0be9b950ddd94f52ebcefe4433ce (diff) |
Don't use serialized propertyinfo
This needs more work before it can be enabled.
Bug: 36001741
Test: boot, check that we're using old style properties
Change-Id: I7032f4b4224758b187cf4e8a53fd8845466a5d4a
Diffstat (limited to 'libc/system_properties/system_properties.cpp')
-rw-r--r-- | libc/system_properties/system_properties.cpp | 22 |
1 files changed, 7 insertions, 15 deletions
diff --git a/libc/system_properties/system_properties.cpp b/libc/system_properties/system_properties.cpp index f67fc4d4a..93184a322 100644 --- a/libc/system_properties/system_properties.cpp +++ b/libc/system_properties/system_properties.cpp @@ -285,19 +285,11 @@ int __system_properties_init() { } contexts = nullptr; if (is_dir(property_filename)) { - if (access("/dev/__properties__/property_info", R_OK) == 0) { - new (&contexts_union.contexts_serialized) ContextsSerialized(); - if (!contexts_union.contexts_serialized.Initialize(false)) { - return -1; - } - contexts = &contexts_union.contexts_serialized; - } else { - new (&contexts_union.contexts_split) ContextsSplit(); - if (!contexts_union.contexts_split.Initialize(false)) { - return -1; - } - contexts = &contexts_union.contexts_split; + new (&contexts_union.contexts_split) ContextsSplit(); + if (!contexts_union.contexts_split.Initialize(false)) { + return -1; } + contexts = &contexts_union.contexts_split; } else { new (&contexts_union.contexts_pre_split) ContextsPreSplit(); if (!contexts_union.contexts_pre_split.Initialize(false)) { @@ -324,9 +316,9 @@ int __system_property_area_init() { } // We set this unconditionally as we want tests to continue on regardless of if this failed // and property_service will abort on an error condition, so no harm done. - new (&contexts_union.contexts_serialized) ContextsSerialized; - contexts = &contexts_union.contexts_serialized; - if (!contexts_union.contexts_serialized.Initialize(true)) { + new (&contexts_union.contexts_split) ContextsSplit; + contexts = &contexts_union.contexts_split; + if (!contexts_union.contexts_split.Initialize(true)) { return -1; } return 0; |