| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
| |
Bug: http://b/21640806
Change-Id: I778b35c8c7538859179e97fcf5a82db2fcd9e50f
(cherry picked from commit 9cf6fc304bbbfb26911e0b624b80d862c40b0308)
|
|
|
|
|
| |
Bug: http://b/20339788
Change-Id: I874c87faa377645fa9e0752f4fc166d81fd9ef7e
|
|
|
|
|
|
|
|
|
| |
The visibility control in pthread_atfork.h is incorrect.
It breaks 64bit libc.so by hiding pthread_atfork.
This reverts commit 6df122f8528f9b9fcf7dfea14ae98b0ef66274e1.
Change-Id: I21e4b344d500c6f6de0ccb7420b916c4e233dd34
|
|
|
|
| |
Change-Id: I326fdf6bb06bed12743f08980b5c69d849c015b8
|
|
|
|
|
|
| |
Bug: http://b/20231984
Bug: http://b/16696563
Change-Id: I71cfddd0d404d1d4a593ec8d3bca9741de8cb90f
|
|
|
|
| |
Change-Id: Ia454a2181b5058ed9783dc02b6b1805d0e4d2715
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
It's okay for a program to choose to drag in stdio, but it's unfortunate
if even the minimal "int main() { return 42; }" drags in stdio...
This brings the minimal static binary on ARM down from 78KiB to 46KiB.
Given that we don't have a separate -lpthread it's not obvious to me that
we can shave this down any further. I'm not sure whether this is a worthwhile
change for that reason. (And the fact that dynamic binaries, the usual case,
are unaffected either way.)
Change-Id: I02f91dcff37d14354314a30b72fed2563f431c88
|
|
|
|
|
| |
Bug: 11156955
Change-Id: I8c72edee8ecb92b75a282384277253bae19f7455
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Register cleanup function with atexit
instead of calling it explicitly on
exit()
* abort() no longer calls _cleanup:
Flushing stdio buffers on abort is no
longer required by POSIX.
* dlmalloc no longer need to reset cleanup
(see above)
* Upstream findfp.c makebuf.c setvbuf.cexit.c
to openbsd versions.
Bug: 14415367
Change-Id: I277058852485a9d3dbb13e5c232db5f9948d78ac
|
|
|
|
|
|
|
|
|
| |
* Ability to register atexit handler from atexit handler
* Correct way to handle both forms of atexit handler
Bug: https://code.google.com/p/android/issues/detail?id=66595
Bug: 4998315
Change-Id: I39529afaef97b6e1469c21389d54c0d7d175da28
|
|
|
|
|
|
| |
This fixes all the bugs found by the new tests.
Change-Id: Id5a5f9f39a0620208bafa053f871a044725b4795
|
|
|
|
|
|
|
|
| |
Adding the perfunctory <ctype.h> tests showed that we'd accidentally
dropped several symbols. This puts everything back in its proper place
and switches us to upstream head at the same time.
Change-Id: Ib527ad280c9baded81e667fa598698526d93e66f
|
|\ |
|
| |
| |
| |
| |
| |
| |
| | |
This is to make it possible to adopt the BSDs' implementations for a few locale
APIs in libc++ rather than writing our own, nearly identical, code.
Change-Id: I482acd4ece83aa4ec9eb0c7acf48f3686794bcc3
|
|/
|
|
|
|
|
|
| |
This gives us a real strtold for LP64 and fixes various LP64
bugs.
Bug: 13563801
Change-Id: I277858d718ee746e136b6b6308a495ba50dfa488
|
|
|
|
|
|
|
| |
The OpenBSD doesn't support C99, and the extent to which we support
locales is trivial, so just do it ourselves.
Change-Id: If0a06e627ecc593f7b8ea3e9389365782e49b00e
|
|
|
|
|
|
|
|
|
|
|
|
| |
lconv is taken from ndk/sources/android/support/include/locale.h and
matches
bsd/glibc upstream.
Keep old declaration for 32-bits for compatibility.
localeconv.c and deps are taken from openbsd upstream.
Changed strtod.c accordingly.
Change-Id: I9fcc4d15f5674d192950d80edf26f36006cd31b4
Signed-off-by: Pavel Chupin <pavel.v.chupin@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The DNS copy of reentrant.h was unused, so remove it.
The strtod implementation can use the upstream-netbsd reentrant.h and
get a little closer to what was then upstream. (It's since been replaced
by gdtoa, and we'll have to follow at some point, but for now this doesn't
make anything any worse.)
ANDROID_CHANGES is (now) only used in the DNS code, so push the -D
down.
The <locale.h> change prevents an LP32 hack from leaking into LP64.
Change-Id: Idf30b98a59d7ca8f7c6cd6d07020b512057911ef
|
|
|
|
|
|
|
|
|
| |
Also undo some of the mess where we have OpenBSD <stdio.h> but a mix of
different BSD's implementations.
In this first pass, I've only moved easy OpenBSD stuff.
Change-Id: Iae67b02cde6dba9d8d06fedeb53efbfdac0a8cf6
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
As of 61e699a133a4807fe878a6cb0d7190d7c96e21f8, stdio clean up
functions are no longer registered in atexit and must be called
manually via __cleanup.
The issue this fixes is some static binaries linked against bionic
cannot output properly when piped or redirected because the buffer
is not flushed before closing.
This is done by pulling in exit.c (and other dependencies) from
netbsd.
Change-Id: I193e54a6d08900f291550029fe75ce76394d9e22
|
|
|
|
|
|
|
| |
This patch adds support for AArch64 to strtod.c definitions.
Change-Id: I9491c4371d921c00e73ae169877a9a71225731fb
Signed-off-by: Serban Constantinescu <serban.constantinescu@arm.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The x86_64 build was failing because clone.S had a call to __thread_entry which
was being added to a different intermediate .a on the way to making libc.so,
and the linker couldn't guarantee statically that such a relocation would be
possible.
ld: error: out/target/product/generic_x86_64/obj/STATIC_LIBRARIES/libc_common_intermediates/libc_common.a(clone.o): requires dynamic R_X86_64_PC32 reloc against '__thread_entry' which may overflow at runtime; recompile with -fPIC
This patch addresses that by ensuring that the caller and callee end up in the
same intermediate .a. While I'm here, I've tried to clean up some of the mess
that led to this situation too. In particular, this removes libc/private/ from
the default include path (except for the DNS code), and splits out the DNS
code into its own library (since it's a weird special case of upstream NetBSD
code that's diverged so heavily it's unlikely ever to get back in sync).
There's more cleanup of the DNS situation possible, but this is definitely a
step in the right direction, and it's more than enough to get x86_64 building
cleanly.
Change-Id: I00425a7245b7a2573df16cc38798187d0729e7c4
|
|
|
|
|
|
| |
This caused trouble for stlport.
Change-Id: Id40787c5a2b7a3a4e12fb557efe549778a01cbbd
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* A dlmalloc usage error shouldn't call abort(3) because we want to
cause a SIGSEGV by writing the address dlmalloc didn't like to an
address the kernel won't like, so that debuggerd will dump the
memory around the address that upset dlmalloc.
* Switch to the simpler FreeBSD/NetBSD style of registering stdio
cleanup. Hopefully this will let us simplify more of the stdio
implementation.
* Clear the stdio cleanup handler before we abort because of a dlmalloc
corruption error. This fixes the reported bug, where we'd hang inside
dlmalloc because the stdio cleanup reentered dlmalloc.
Bug: 9301265
Change-Id: Ief31b389455d6876e5a68f0f5429567d37277dbc
|
|
|
|
| |
Change-Id: Ic46cd0b663dc5fa78c99dd38db0bfe849a25e789
|
|
|
|
| |
Change-Id: Ib9eb167710a021e0a2b5c77a06a9338cdc748e6d
|
|
|
|
|
|
|
|
| |
There's now only one place where we deal with this stuff, it only needs to
be parsed once by the dynamic linker (rather than by each recipient), and it's
now easier for us to get hold of auxv data early on.
Change-Id: I6314224257c736547aac2e2a650e66f2ea53bef5
|
|
|
|
| |
Change-Id: Idb781d37de3b05585271d7d258ecffd5ba87d0b8
|
|
|
|
|
|
|
| |
I'll need at least one more pass, because there's some upstream code
lurking in libc/bionic, but this is still a step in the right direction.
Change-Id: I55927315972da8327ae01c5240ed587db17e8462
|
|
|
|
|
|
| |
Missed this in 774c7f54ff375d71106283d42779b0cc5f238f87.
Change-Id: Ic24fd67f003d0e2d192cfb08f96f63024ca817eb
|
|
|
|
|
|
| |
Also add basic unit tests.
Change-Id: I7fc7ef61d47c1e8fdf8b8eff67a635220c3afd56
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
To properly support legacy ARM shared libraries, libc.so needs
to export the symbols __dso_handle and atexit, even though
these are now supplied by the crt startup code.
This patch reshuffles the existing CRT_LEGACY_WORKAROUND
conditionally compiled code slightly so it works as the
original author likely intended.
Change-Id: Id6c0e94dc65b7928324a5f0bad7eba6eb2f464b9
Signed-off-by: Ard Biesheuvel <ard.biesheuvel@gmail.com>
|
|
|
|
|
|
|
|
| |
__cxa_finalize() modifies the access permissions of __atexit
global variable without acquiring _ATEXIT_LOCK(). Fix it prevent
any possible races.
Change-Id: I11939d0ebcbf6f360c14163222d40a449d96948e
|
|
|
|
|
|
|
|
|
|
| |
In particular this affects assert(3) and __cxa_pure_virtual, both of
which have managed to confuse people this week by apparently aborting
without reason. (Because stderr goes nowhere, normally.)
Bug: 6852995
Bug: 6840813
Change-Id: I7f5d17d5ddda439e217b7932096702dc013b9142
|
|\
| |
| |
| |
| | |
* commit '1c0a0381dfb3648ffadef9537ec9383d63d62473':
Enable functional DSO object destruction
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Unfortunately, legacy .so files for ARM don't have a correct crtbegin file.
Consequently, we have to grandfather the old __dso_handle behaviour.
Add some ifdefs for ARM to allow it to use the old code until we can work
out a transition.
Change-Id: I6a28f368267d792c94e1d985d8344023bc632f6f
Author: H.J. Lu <hongjiu.lu@intel.com>
Signed-off-by: Bruce Beare <bruce.j.beare@intel.com>
|
|/
|
|
| |
Change-Id: I739a06f9037a9fb643276f61601f0f3e192581b8
|
|
|
|
|
|
|
| |
The source file is not part of the C library build, so the Android.mk
is unaffected. In other words, this source file was never compiled.
Change-Id: Idec3d5b6ec30dc9ee38296d12dc6e522997df29a
|
|\
| |
| |
| |
| |
| |
| | |
Merge commit '958214aa998d9378e7d70c7c08ffab4c5f9d3fde'
* commit '958214aa998d9378e7d70c7c08ffab4c5f9d3fde':
stdlib: strtod: Hide internal symbol __dtoa
|
| |\
| | |
| | |
| | |
| | |
| | |
| | | |
Merge commit '8ad63d745d4ec1edea0bbd04fd0644983ad77bf5' into gingerbread-plus-aosp
* commit '8ad63d745d4ec1edea0bbd04fd0644983ad77bf5':
stdlib: strtod: Hide internal symbol __dtoa
|
| | |
| | |
| | |
| | | |
Change-Id: Iaaec7ea4d04c859fe98ad3331fd71e7d000c826b
|
|\ \ \
| |/ /
| | |
| | |
| | |
| | |
| | | |
Merge commit 'cb0f5ed8111d4305cf6798aefdb4f9623570c83a'
* commit 'cb0f5ed8111d4305cf6798aefdb4f9623570c83a':
Remove compiler warnings when building Bionic.
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Also add missing declarations to misc. functions.
Fix clearerr() implementation (previous was broken).
Handle feature test macros like _POSIX_C_SOURCE properly.
Change-Id: Icdc973a6b9d550a166fc2545f727ea837fe800c4
|
|/ /
| |
| |
| |
| |
| | |
Added wcsxfrm.c and wmemcmp.c to the src files in Android.mk and removed wcsxfrm from wchar.c
Change-Id: Iab9b45cf78c27880d2941c360340a7af6b8964fe
|
|/
|
|
| |
Change-Id: Iffd41046fd0933c66542abf7627a1569522dfcb2
|
|\
| |
| |
| | |
Change-Id: If02d33af51017dbd85e91c79ac2e848eda6cf253
|
| |
| |
| |
| |
| |
| | |
Signed-off-by: André Goddard Rosa <andre.goddard@gmail.com>
Change-Id: I7dd90a0816b5376ffc1de4499d56935e0bd574a1
|
|\ \
| |/
| |
| | |
Change-Id: I950e9aca87cbb0c35099b1d53cff6378bd0f26f4
|
| |
| |
| |
| |
| |
| |
| | |
... by checking most probable condition first (elements do differ)
Change-Id: I424eab9c32a6d9eb82b686ca04025ec8c9097035
Signed-off-by: André Goddard Rosa <andre.goddard@gmail.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
To avoid introducing NULL checks everytime a Bigint computation
is performed, introduce a special value (BIGINT_INVALID) and only
check for it when absolutely needed (which means when the code
needs to access the Bigint's internal structure fields).
Change-Id: Ie3954523b0985b6a8cb62340802d8dcf63cbf16f
|