Cast the constant (which should probably be unsigned in the kernel headers, but isn't), rather than the already [correctly] unsigned expression involving `c_cflag`.
This came up when there was a suggestion on the linux-api mailing list [https://lore.kernel.org/linux-api/be31d737-8263-4e59-8b30-7221ee0549fc@cs.ucla.edu/T/#mdd466d7eaefe8805de7b0cecf013c5cddb04c660] to maybe change the signedness of the constants; this was the only build breakage that would result in AOSP from doing so.
Change-Id: I64aeee0a8f5d2edd54a9a9352b1aa2b9e3aa245e
Similar to mmap(), this confuses me every time I look at it. Move it out
of the way, and make it clearer that this is just junk that can be
deleted when we remove 32-bit support.
Also improve coverage by adding a test for the varargs special case.
Test: treehugger
Merged-in: Ia375c29d18e31e646b795e643534f0be07d382b9
Change-Id: Ia375c29d18e31e646b795e643534f0be07d382b9
Also group all the RELR/arm64/riscv64 bits together rather than mixing them up slightly as we'd done so far.
Change-Id: Iff1ea2cfca9ff702b88aa2e7d09db46e2f34f965
Fail to compile bionic/tests/complex_test.cpp when updating compiler due
to the conflict.
Bug: b/346349678
Test: change the clang version and then run mm to build
Change-Id: Ic22b7325b6e52006e620e13944f3f1d76030d782
libz is no longer statically linked into libunwindstatck, so needs to be
added explicitly to this rdep
Bug: 281077552
Test: presubmits
Change-Id: Iadcee0c8b98ce4cfd3e238e7e4b3a3becc315e6c
Add basic assembly stubs for TLS Descriptor support in the dynamic
linker, and enable several code paths related to TLSDESC for RISC-V.
Note: This patch requires an updated toolchain that supports TLSDESC
for RISC-V, and the `-mtls-dialect=` compiler option specifically.
Test: adb shell /data/nativetest64/bionic-unit-tests/bionic-unit-tests --gtest_filter=*tls*
Bug: 322984914
Change-Id: I74bd0fa216b44b4ca2c5a5a6aec37b3fc47b00d9
Every time I look at mmap.cpp, I fail to realize it's only built for ILP32.
Also improve some of the commentary in SYSCALLS.TXT and legacy_32_bit_support.cpp.
Change-Id: Ieedfe800b437e30c060c3e8663b6d96d517dbf6f
clang-19 and later default to C++14 sized deallocation. Currently we don't have C23's C equivalent of free_sized(), so we just implement these in terms of free() for now.
Bug: http://b/344993254
Change-Id: I708710aee3f7a684bfe494a96f7baed014acbe57
I was actually here to add some new documentation, but realized there wasn't really a good place to put it...
Change-Id: I8a2fc93e61a89e87aa53dd0beb9dfcc6561687ca
Not a security problem, but definitely a bug if you're calling this and ignoring the result, since it has no side-effects.
(All of the more important functions -- realloc() especially -- are already annotated.)
Change-Id: I217463518b4716befcc0ed9426648eafbfbbdde4
Kernel headers coming from:
Git: https://android.googlesource.com/kernel/common/
Branch: android-mainline
Tag: android-mainline-6.9
Test: Builds and bionic unit tests pass on raven.
Test: Able to log in to an Android GO 32 bit device.
Change-Id: If53a38bbb65c3c653ce790fe5c6e51597901a14e
This is just POSIX nonsense. Android, iOS/macOS, the BSDs, and glibc all have getpagesize(). Window doesn't, but Windows doesn't have sysconf(3) either, so there's not a strong "portability" argument to be had there!
Change-Id: Ieacfbb61c3612045f27c20c3fa4fa12694db2243
The setjmp implementation is correct, but this comment was wrong, and we were missing the implementation of the test. This would be slightly simpler if we enabled Zfa in the build system and qemu, but this works for now.
Change-Id: Iad32771019584beacd8b35138ac2bf4c0a14c903