Update status.md.
We were still using "Android O" in developer-facing documentation, we'd forgotten to document the destroyed pthread_mutex_t behavior change, and we'd forgotten to document the existence of _Fork() and <android/crash_detail.h>. Change-Id: Ie2c94a1956b7252472116cacc90f38fa4e2dd229
This commit is contained in:
parent
5a42460cc6
commit
a459c0b066
1 changed files with 19 additions and 7 deletions
|
@ -56,7 +56,11 @@ list of POSIX functions implemented by glibc but not by bionic.
|
|||
Current libc symbols: https://android.googlesource.com/platform/bionic/+/main/libc/libc.map.txt
|
||||
|
||||
New libc functions in V (API level 35):
|
||||
* `tcgetwinsize`, `tcsetwinsize` (POSIX Issue 8 additions).
|
||||
* New `android_crash_detail_register`, `android_crash_detail_unregister`,
|
||||
`android_crash_detail_replace_name`, and `android_crash_detail_replace_data`
|
||||
functionality for adding arbitrary data to tombstones
|
||||
(see `<android/crash_detail.h>` for full documentation).
|
||||
* `tcgetwinsize`, `tcsetwinsize`, `_Fork` (POSIX Issue 8 additions).
|
||||
* `timespec_getres` (C23 addition).
|
||||
* `localtime_rz`, `mktime_z`, `tzalloc`, and `tzfree` (NetBSD
|
||||
extensions implemented in tzcode, and the "least non-standard"
|
||||
|
@ -321,17 +325,25 @@ New libm functions in J-MR2 (API level 18):
|
|||
## Target API level behavioral differences
|
||||
|
||||
Most bionic bug fixes and improvements have been made without checks for
|
||||
the app's `targetSdkVersion`. As of O there were exactly two exceptions,
|
||||
but there are likely to be more in future because of Project Treble.
|
||||
the app's `targetSdkVersion`. There are a handful of exceptions. (If in
|
||||
doubt, search the source for `android_get_application_target_sdk_version()`.)
|
||||
|
||||
### Invalid `pthread_t` handling (targetSdkVersion >= O)
|
||||
### Destroyed mutex checking (targetSdkVersion >= 28)
|
||||
|
||||
If a destroyed `pthread_mutex_t` is passed to any of the mutex functions, apps
|
||||
targeting API level 28 or higher will see a
|
||||
"<function> called on a destroyed mutex" fortify failure. Apps targeting older
|
||||
API levels will just have the function fail with EBUSY (matching the likely
|
||||
behavior before we added the check).
|
||||
|
||||
### Invalid `pthread_t` handling (targetSdkVersion >= 26)
|
||||
|
||||
As part of a long-term goal to remove the global thread list,
|
||||
and in an attempt to flush out racy code, we changed how an invalid
|
||||
`pthread_t` is handled. For `pthread_detach`, `pthread_getcpuclockid`,
|
||||
`pthread_getschedparam`/`pthread_setschedparam`, `pthread_join`, and
|
||||
`pthread_kill`, instead of returning ESRCH when passed an invalid
|
||||
`pthread_t`, if you're targeting O or above, they'll abort with the
|
||||
`pthread_t`, if you're targeting API level 26 or above, they'll abort with the
|
||||
message "attempt to use invalid pthread\_t".
|
||||
|
||||
Note that this doesn't change behavior as much as you might think: the
|
||||
|
@ -369,13 +381,13 @@ To fix your code, taking the affected functions one by one:
|
|||
the tid may have been reused, but your code is inherently unsafe without
|
||||
a redesign anyway.
|
||||
|
||||
### Interruptable `sem_wait` (targetSdkVersion >= N)
|
||||
### Interruptable `sem_wait` (targetSdkVersion >= 24)
|
||||
|
||||
POSIX says that `sem_wait` can be interrupted by delivery of a
|
||||
signal. This wasn't historically true in Android, and when we fixed this
|
||||
bug we found that existing code relied on the old behavior. To preserve
|
||||
compatibility, `sem_wait` can only return EINTR on Android if the app
|
||||
targets N or later.
|
||||
targets API level 24 or later.
|
||||
|
||||
|
||||
## FORTIFY
|
||||
|
|
Loading…
Reference in a new issue