ChokkaUoM / address-sanitizer

Automatically exported from code.google.com/p/address-sanitizer
0 stars 0 forks source link

[android] system property access from native code is going away #392

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
64-bit toolchains in the new NDK releases are missing __system_property_* 
symbols. ASan needs those to read asan.options on startup.

Workarounds:
1. Go through Java. Not an option, as there is no Java (either that early, or 
at all, in the case of a standalone executable).
2. open a device (or is it a file?) and parse properties in sanitizer code. 
They are kept in a trie, so that could be complicated. Also, fragile.
3. dlopen libcutils.so and find property_get() or something.
4. fork-exec /system/bin/getprop

Original issue reported on code.google.com by euge...@google.com on 9 Jun 2015 at 11:01

GoogleCodeExporter commented 9 years ago
Also, system properties are initialized in libc_init_common and do not work 
from .preinit_array.

Original comment by euge...@google.com on 20 Jul 2015 at 7:48

GoogleCodeExporter commented 9 years ago
Adding Project:AddressSanitizer as part of GitHub migration.

Original comment by ramosian.glider@gmail.com on 30 Jul 2015 at 9:06