summaryrefslogtreecommitdiffstats
path: root/tests
Commit message (Collapse)AuthorAgeFilesLines
* Unregister pthread_atfork handlers on dlclose()Dmitriy Ivanov2015-04-224-9/+120
| | | | Change-Id: I326fdf6bb06bed12743f08980b5c69d849c015b8
* add fortified readlink/readlinkat implementationsDaniel Micay2015-04-171-0/+12
| | | | Change-Id: Ia4b1824d20cad3a072b9162047492dade8576779
* Merge "Support symbol versioning"Dmitriy Ivanov2015-04-1713-0/+413
|\
| * Support symbol versioningDmitriy Ivanov2015-04-1613-0/+413
| | | | | | | | | | Bug: http://b/20139821 Change-Id: I64122a0fb0960c20b2ce614161b7ab048456b681
* | add fortified implementations of pread/pread64Daniel Micay2015-04-161-0/+16
| | | | | | | | Change-Id: Iec39c3917e0bc94371bd81541619392f5abe29b9
* | Merge "Call __cxa_thread_finalize for the main thread."Dmitriy Ivanov2015-04-161-0/+23
|\ \
| * | Call __cxa_thread_finalize for the main thread.Dmitriy Ivanov2015-04-151-0/+23
| | | | | | | | | | | | | | | | | | Bug: http://b/20231984 Bug: http://b/16696563 Change-Id: I71cfddd0d404d1d4a593ec8d3bca9741de8cb90f
* | | Merge "Change on handling of SIGEV_THREAD timers."Yabin Cui2015-04-161-69/+71
|\ \ \ | |_|/ |/| |
| * | Change on handling of SIGEV_THREAD timers.Yabin Cui2015-04-151-69/+71
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 1. Don't prevent calling callback when SIGEV_THREAD timers are disarmed by timer_settime. As in POSIX standard: The effect of disarming or resetting a timer with pending expiration notifications is unspecified. And glibc didn't prevent in this situation, so I think it is fine to remove the support. 2. Still prevent calling callback when SIGEV_THREAD timers are deleted by timer_delete. As in POSIX standard: The disposition of pending signals for the deleted timer is unspecified. However, glibc handles this (although that is not perfect). And some of our tests in time_test.cpp depend on this feature as described in b/18039727. so I retain the support. 3. Fix some flaky test in time_test.cpp, and make "time*" test pass on bionic-unit-tests-glibcxx. Bug: 18263854 Change-Id: I8ced184eacdbfcf433fd81b0c69c38824beb8ebc
* | | Hide emutls* symbols in libc.soDmitriy Ivanov2015-04-151-1/+1
| |/ |/| | | | | | | | | | | Also make thread_local in test static to avoid ld.bfd warning for arm64. Change-Id: I09a3f2aa9b73a4fafa3f3bbc64ddc2a128ad50ee
* | Merge "Prevent using static-allocated pthread keys before creation."Yabin Cui2015-04-141-0/+13
|\ \ | |/ |/|
| * Prevent using static-allocated pthread keys before creation.Yabin Cui2015-04-141-0/+13
| | | | | | | | | | | | Bug: 19993460 Change-Id: I244dea7f5df3c8384f88aa48d635348fafc9cbaf
* | Merge "Fix dl* tests to run-on-host"Dmitriy Ivanov2015-04-112-2/+10
|\ \
| * | Fix dl* tests to run-on-hostDmitriy Ivanov2015-04-092-2/+10
| | | | | | | | | | | | | | | Bug: http://b/20121152 Change-Id: I1e1f41d885c75dbb26f91565a53a15d62ef72ce6
* | | Merge "Provide writer preference option in rwlock."Yabin Cui2015-04-091-2/+136
|\ \ \ | |/ / |/| |
| * | Provide writer preference option in rwlock.Yabin Cui2015-04-081-2/+136
| |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Previous implementation of rwlock contains four atomic variables, which is hard to maintain and change. So I make following changes in this CL: 1. Add pending flags in rwlock.state, so we don't need to synchronize between different atomic variables. Using compare_and_swap operations on rwlock.state is enough for all state change. 2. Add pending_lock to protect readers/writers waiting and wake up operations. As waiting/wakeup is not performance critical, using a lock is easier to maintain. 3. Add writer preference option. 4. Add unit tests for rwlock. Bug: 19109156 Change-Id: Idcaa58d695ea401d64445610b465ac5cff23ec7c
* | Fix x86_64 buildDmitriy Ivanov2015-04-061-1/+1
| | | | | | | | Change-Id: Id81c059bf3ecdb9cc84d04d16ffda34baaadc5a1
* | Merge "Add realpath for soinfo"Dmitriy Ivanov2015-04-073-21/+122
|\ \
| * | Add realpath for soinfoDmitriy Ivanov2015-04-063-21/+122
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This change adds realpath to soinfo and extends limit on filenames from 128 to PATH_MAX. It also removes soinfo::name field, linker uses dt_soname instead. Bug: http://b/19818481 Bug: https://code.google.com/p/android/issues/detail?id=80336 Change-Id: I9cff4cb5bda3ee2bc74e1bbded9594ea7fbe2a08
* | | Merge "Add a test for getdelim(3) on a directory."Elliott Hughes2015-04-061-0/+9
|\ \ \ | |_|/ |/| |
| * | Add a test for getdelim(3) on a directory.Elliott Hughes2015-04-051-0/+9
| | | | | | | | | | | | | | | | | | | | | Apparently uClibc has a bug here. We don't, but let's keep it that way. Bug: http://landley.net/notes.html#21-03-2015 Change-Id: If406df963db9bee47921d7a1c116ebcab08d96bf
* | | Merge "Fix bug for recursive/errorcheck mutex on 32-bit devices."Yabin Cui2015-04-043-18/+51
|\ \ \ | |_|/ |/| |
| * | Fix bug for recursive/errorcheck mutex on 32-bit devices.Yabin Cui2015-04-033-18/+51
| | | | | | | | | | | | | | | Bug: 19216648 Change-Id: I3b43b2d18d25b9bde352da1e35f9568133dec7cf
* | | Add libdl dependency for target librariesDmitriy Ivanov2015-04-031-6/+3
| |/ |/| | | | | | | | | Fixed x86_64 target build with gcc 4.9 Change-Id: Id3b1e9286c2bcbb8e3ac117bcef957304db7cfd3
* | Merge "Add ANDROID_DLEXT_FORCE_LOAD flag"Dmitriy Ivanov2015-04-031-0/+34
|\ \ | |/ |/|
| * Add ANDROID_DLEXT_FORCE_LOAD flagDmitriy Ivanov2015-04-031-0/+34
| | | | | | | | | | | | | | | | | | This flag allows to force loading of the library in the case when for some reason multiple ELF files share the same filename (because the already-loaded library has been removed and overwritten, for example). Change-Id: I798d44409ee13d63eaa75d685e99c4d028d2b0c1
* | Merge "Look into local group on dlsym with RTLD_DEFAULT"Dmitriy Ivanov2015-04-023-1/+61
|\ \
| * | Look into local group on dlsym with RTLD_DEFAULTDmitriy Ivanov2015-04-023-1/+61
| |/ | | | | | | | | | | | | | | Fix dlsym to look into local group when called with RTLD_DEFAULT and RTLD_NEXT. Bug: 17512583 Change-Id: I541354e89539c712af2ea4ec751e546913027084
* | Merge "Refactor pthread_mutex to support 32-bit owner_tid on 64-bit devices."Yabin Cui2015-04-021-2/+5
|\ \
| * | Refactor pthread_mutex to support 32-bit owner_tid on 64-bit devices.Yabin Cui2015-04-011-2/+5
| | | | | | | | | | | | | | | Bug: 19216648 Change-Id: I765ecacc9036659c766f5d1f6600e1a65364199b
* | | Merge "gtest_repeat should allow negative values."Christopher Ferris2015-04-021-11/+10
|\ \ \ | |_|/ |/| |
| * | gtest_repeat should allow negative values.Christopher Ferris2015-04-021-11/+10
| |/ | | | | | | | | | | | | If you pass in a negative value to gtest_repeat, it should run forever. The new runner didn't allow this, now it does. Change-Id: Ie0002c12e2fdad22b264adca37c165cfcfe05c7a
* | Fix ftw tests when run as non-root.Elliott Hughes2015-04-011-3/+3
| | | | | | | | | | | | | | Root can create subdirectories inside non-writable directories, but other users can't. Change-Id: I102fe610d1bd2733aebf184b544e58612465287d
* | Make ThreadLocalBuffer a class rather than a macro.Elliott Hughes2015-03-311-2/+1
|/ | | | | Bug: 19995392 Change-Id: I497c512648fbe66257da3fb3bcd5c9911f983705
* Add test for thread_local keyword.Dmitriy Ivanov2015-03-272-0/+34
| | | | | | | | For gcc only for the time being. Bug: 19800080 Bug: 16696563 Change-Id: Ifaa59a131ca2d9030554cee7ce631dcb1d081938
* Merge "Revert "Cause Fatal error when invalid pthread_id is detected.""Yabin Cui2015-03-261-39/+7
|\
| * Revert "Cause Fatal error when invalid pthread_id is detected."Yabin Cui2015-03-261-39/+7
| | | | | | | | | | | | | | | | Some code like in https://buganizer.corp.google.com/u/0/issues/19942911 need to change first. This reverts commit 03324780aae9ff28c8acf52debf0ea39120e5ab8. Change-Id: I13ff1e5b3d0672bae9cde234ffba32fbbf33d338
* | Merge "Initial implementation of __cxa_thread_atexit_impl"Dmitriy Ivanov2015-03-262-0/+76
|\ \
| * | Initial implementation of __cxa_thread_atexit_implDmitriy Ivanov2015-03-252-0/+76
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is initial implementations; does not yet handle dlclose - undefined behavior, needs linker support to handle it right. Bug: 19800080 Bug: 16696563 Change-Id: I7a3e21ed7f7ec01e62ea1b7cb2ab253590ea0686
* | | Hide internal of pthread_mutex_t.Yabin Cui2015-03-251-50/+82
| |/ |/| | | | | | | Bug: 19249079 Change-Id: Iffb79c8d861b698d474f212dc80c638fc2cf1620
* | Cause Fatal error when invalid pthread_id is detected.Yabin Cui2015-03-251-7/+39
|/ | | | | | | | | This is a patch testing whether we can use abort() instead of returning ESRCH for invalid pthread ids. It is an intermediate step to remove g_thread_list/g_thread_list_lock. Bug: 19636317 Change-Id: Idd8e4a346c7ce91e1be0c2ebcb78ce51c0d0a31d
* Add test for pthread types alignment check.Yabin Cui2015-03-201-0/+58
| | | | | Bug: 19249079 Change-Id: I83c4f0d11ec5d82a346ae0057d02a92bb1d519e8
* Return EINVAL when calling pthread_detach for joined thread.Yabin Cui2015-03-191-1/+4
| | | | Change-Id: I717015132187e087e0ad485284a13c8801e25e77
* Move open from zip tests to dlextDmitriy Ivanov2015-03-182-69/+50
| | | | | | | | To avoid building them for glibc. Also replace snprintf with std::string Change-Id: I12e1d2e4ab46ff5af6c05453da67842e0d838fc5
* Implement lookup by DT_SONAMEDmitriy Ivanov2015-03-182-0/+37
| | | | | | | | | This CL also fixes SEARCH_NAME hack and resolves https://code.google.com/p/android/issues/detail?id=6670 once and for all. Bug: https://code.google.com/p/android/issues/detail?id=6670 Change-Id: I9b8d6a672cd722f30fbfbb40cdee8d9b39cfe56e
* Merge "Hide statfs/fstatfs' ST_VALID flag from userspace."Elliott Hughes2015-03-182-0/+12
|\
| * Hide statfs/fstatfs' ST_VALID flag from userspace.Elliott Hughes2015-03-182-0/+12
| | | | | | | | | | | | Spotted while debugging the strace 4.10 upgrade. Change-Id: I1af1be9c9440151f55f74a835e1df71529b0e4fe
* | Merge "Support loading shared libraries from zip files"Dimitry Ivanov2015-03-182-3/+51
|\ \ | |/ |/|
| * Support loading shared libraries from zip filesSimon Baldwin2015-03-162-3/+51
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add code to support loading shared libraries directly from within APK files. Extends the linker's handling of LD_LIBRARY_PATH, DT_RUNPATH, etc to allow elements to be either directories as normal, or ZIP format files. For ZIP, the ZIP subdirectory string is separated from the path to file by '!'. For example, if DT_NEEDED is libchrome.so and Chrome.apk is the Android ARM APK then the path element /system/app/Chrome.apk!lib/armeabi-v7a would cause the linker to load lib/armeabi-v7a/libchrome.so directly from inside Chrome.apk. For loading to succeed, libchrome.so must be 'stored' and not compressed in Chrome.apk, and must be page aligned within the file. Motivation: Chromium tracking issue: https://code.google.com/p/chromium/issues/detail?id=390618 Bug: 8076853 Change-Id: Ic49046600b1417eae3ee8f37ee98c8ac1ecc19e7
* | set errno to ENOENT in getauxval per glibc 2.19Daniel Micay2015-03-171-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | Bionic's getauxval(...) implementation returns zero when entries are missing. Zero can be a valid value, so there is no unambiguous way of detecting an error. Since glibc 2.19, errno is set to ENOENT when an entry is missing to make it possible to detect this. Bionic should match this behavior as code in the Linux ecosystem will start relying on it to check for the presence of newly added entries. Change-Id: Ic1efe29bc45fc87489274c96c4d2193f3a7b8854 Signed-off-by: Daniel Micay <danielmicay@gmail.com>