Commit graph

3407 commits

Author SHA1 Message Date
Elliott Hughes
3fac8f7f49 Regenerate msm_ion.h.
Bug: 8000377
Change-Id: If496d9972cb8aebfc996ac641aa762220aa71f3b
2013-02-01 18:21:08 -08:00
Elliott Hughes
3dc6b57cf5 Merge "Don't claim there were no leaks if we weren't even checking." 2013-02-02 01:18:44 +00:00
Elliott Hughes
9c81892c2e Don't claim there were no leaks if we weren't even checking.
Bug: 8107016
Change-Id: I9059f1f8374ebcdf00dfc6ac74d3709f501292c9
2013-02-01 17:07:40 -08:00
Elliott Hughes
1bf835558a Merge "Make sincosl call sinl and cosl." 2013-02-02 00:42:01 +00:00
Elliott Hughes
9b05df325c Make sincosl call sinl and cosl.
Bug: 2748728
Change-Id: Id18070963b91b144758c567ad7ac80758e3a638b
2013-02-01 16:32:50 -08:00
Elliott Hughes
ae70b94674 Merge "Update the libm/NOTICE file after the upgrade." 2013-02-02 00:26:12 +00:00
Elliott Hughes
d65bd8400e Update the libm/NOTICE file after the upgrade.
Change-Id: Icf9c44402d6f86117d61307219bb1cccd288854d
2013-02-01 16:16:54 -08:00
Elliott Hughes
a9dd36702f Merge "Restore bionic's <linux/elf-em.h>." 2013-02-02 00:11:33 +00:00
Elliott Hughes
a48e1b2aac Restore bionic's <linux/elf-em.h>.
Used by <linux/audit.h>.

Change-Id: Ica4ebb7f52a7fce13c52fdff35e187ded3939382
2013-02-01 16:10:28 -08:00
Elliott Hughes
44badc70cc Merge "Upgrade libm." 2013-02-01 23:07:49 +00:00
Elliott Hughes
a0ee07829a Upgrade libm.
This brings us up to date with FreeBSD HEAD, fixes various bugs, unifies
the set of functions we support on ARM, MIPS, and x86, fixes "long double",
adds ISO C99 support, and adds basic unit tests.

It turns out that our "long double" functions have always been broken
for non-normal numbers. This patch fixes that by not using the upstream
implementations and just forwarding to the regular "double" implementation
instead (since "long double" on Android is just "double" anyway, which is
what BSD doesn't support).

All the tests pass on ARM, MIPS, and x86, plus glibc on x86-64.

Bug: 3169850
Bug: 8012787
Bug: https://code.google.com/p/android/issues/detail?id=6697
Change-Id: If0c343030959c24bfc50d4d21c9530052c581837
2013-02-01 14:51:19 -08:00
Elliott Hughes
e1a124e5c9 Merge "Say explicitly if there were no leaks." 2013-01-30 19:53:49 +00:00
Elliott Hughes
1d12d57416 Say explicitly if there were no leaks.
Otherwise people trying to use this are left wondering "did I not leak, or did
the leak checking code not get called when I exited?".

Change-Id: If79b225f8a2e24dd69aba1fb836bf9e81bb00efe
2013-01-30 11:38:26 -08:00
Elliott Hughes
a990cf5b33 Merge "Clean up trailing whitespace in the kernel headers." 2013-01-30 18:13:29 +00:00
Elliott Hughes
c95eb57405 Clean up trailing whitespace in the kernel headers.
And fix the scripts so they stop letting trailing whitespace through.

Change-Id: Ie109fbe1f63321e565ba0fa60fee8e9cf3a61cfc
2013-01-30 10:13:07 -08:00
Elliott Hughes
323287ea7f Merge "Fix valgrind build." 2013-01-30 01:50:16 +00:00
Elliott Hughes
6fe67c3cf2 Fix valgrind build.
Change-Id: Ie375d32565d10f4c0c56da5422f52b68cb069654
2013-01-29 17:49:12 -08:00
Elliott Hughes
f67219783f Merge "Fix x86 build to use <elf.h>." 2013-01-30 00:41:24 +00:00
Elliott Hughes
d070df4c74 Fix x86 build to use <elf.h>.
Change-Id: I7b697d5eae69dc08eb31471a42cb8bbe5360be76
2013-01-29 16:40:39 -08:00
Elliott Hughes
5fb409b7b0 Merge "Bring the NOTICE files back up to date." 2013-01-30 00:33:53 +00:00
Elliott Hughes
448080d372 Bring the NOTICE files back up to date.
Change-Id: I978275cf6604b90595ee79d897c0460eeadc7dc8
2013-01-29 16:25:06 -08:00
Elliott Hughes
f09f6db5dd Merge "Use the NetBSD <sys/exec_elf.h>." 2013-01-30 00:06:11 +00:00
Elliott Hughes
a6a3ac5924 Use the NetBSD <sys/exec_elf.h>.
Replace a kernel header file dependency with files from NetBSD.
They're more complete, and ELF is ELF, whether you're on Linux or a BSD.

Bug: 7973611
Change-Id: I83ee719e7efdf432ec2ddbe8be271d05b2f558d7
2013-01-29 15:02:50 -08:00
Elliott Hughes
3db2fc5acb Merge "Don't collect useless stack frames; do demangle C++ symbols." 2013-01-29 19:59:30 +00:00
Elliott Hughes
35b621c5f4 Don't collect useless stack frames; do demangle C++ symbols.
Previously, we'd collect every stack frame and then throw some away
when we came to log them. This meant that stack traces were effectively
shorter than the buffers that had been allocated for them. This patch
only stores frames we'll actually output.

Also dynamically call the C++ demangler so we don't have to try to
read mangled names. Because no one knows the mangling of operator new[]
for int arrays off the top of their head.

Bug: 7291287
Change-Id: I42b022fd7cd61675d05171de4c3b2704d058ef2a
2013-01-29 09:56:31 -08:00
Elliott Hughes
a0151cbfba Merge "Unit tests for formatting code, fix %%." 2013-01-28 22:04:45 +00:00
Elliott Hughes
41b3179c9e Unit tests for formatting code, fix %%.
Also fix <signal.h> and <stdio.h> so they don't cause compiler warnings.

Change-Id: Ib1a746bf01de22d47dbd964de0e6af80a7c96303
2013-01-28 10:36:31 -08:00
Elliott Hughes
0a91b11d28 Merge "More debug malloc fixes." 2013-01-26 01:55:43 +00:00
Elliott Hughes
239e7a0756 More debug malloc fixes.
Include the leaky executable's name in the log output. Fix the "sh" test.
Use uintptr_t instead of intptr_t.

Also fix debug formatting of NULL with %s.

Bug: 7291287
Change-Id: I015bf341cd48d43a247173612e6ccb1bf1243d53
2013-01-25 17:13:45 -08:00
Elliott Hughes
6a94cb748b Merge "arm syscall : for eabi call_default don't use stack" 2013-01-25 21:57:58 +00:00
Nick Kralevich
b871e5d6b3 Merge "system_properties: do more checking of file" 2013-01-25 21:52:00 +00:00
Nick Kralevich
c16961b8c3 system_properties: do more checking of file
Check that the permissions on the properties file
are exactly as we expect them to be.

Make sure we close the fd if fstat fails.

Refactor the code slightly.

Change-Id: I5503fd58c3b8093ce7e6d05920748ed70eaf8e2c
2013-01-25 13:07:31 -08:00
Nick Kralevich
82ef8296dc Merge "prctl.h: include sys/cdefs.h" 2013-01-24 16:44:59 +00:00
Nick Kralevich
8e70b0d5c3 prctl.h: include sys/cdefs.h
prctl.h uses __BEGIN_DECLS but fails to include sys/cdefs.h
(where it's defined).  Code which includes prctl.h without
previously including sys/cdefs.h will fail to compile.

Fixed.

Change-Id: If4c9f3308f08b93596dcd00e351ae786807e9320
2013-01-23 16:49:47 -08:00
Nick Kralevich
b3351f1204 Merge "libc: use more secure system properties if available" 2013-01-23 18:50:24 +00:00
Nick Kralevich
32417fb376 libc: use more secure system properties if available
Currently, system properties are passed via the environment
variable ANDROID_PROPERTY_WORKSPACE and a file descriptor passed
from parent to child. This is insecure for setuid executables,
as the environment variable can be changed by the caller.

Modify system property handling so that we get the properties
from a root owned properties file, rather than using an
environment variable.  Fall back to the environment variable
if the file doesn't exist.

Bug: 8045561
Change-Id: I54f3efa98cf7d63d88788da5ce0d19e34fd7851a
2013-01-23 09:28:35 -08:00
Elliott Hughes
778a68e1e5 Merge "Don't free anything when reporting leaks." 2013-01-23 06:06:21 +00:00
Elliott Hughes
5c8f75ef8b Merge "Disable leak checking for mksh; it's way too leaky." 2013-01-23 06:05:19 +00:00
Elliott Hughes
848247a972 Don't free anything when reporting leaks.
We don't know that they're not going to be cleaned up by a
C++ global destructor that runs after us. This is the case with
bootanimation, for example.

Bug: 7291287
Change-Id: Iba402514d1735fdc2ae4bc95b65396d816be46c0
2013-01-22 18:36:28 -08:00
Elliott Hughes
84f8b5f401 Disable leak checking for mksh; it's way too leaky.
When each shell leaks ~240 allocations, you can't see the leaks from
the program you ran with "adb shell".

Bug: 7291287
Change-Id: Ib8780db72ba0114ebdb24768537da74bbb61f354
2013-01-22 18:35:14 -08:00
Elliott Hughes
28f82b260c Merge "Add const for first argument of sigismember for fit POSIX spec" 2013-01-23 01:11:28 +00:00
Elliott Hughes
8d6302cdcf Merge "Our strcoll(3) is no different from NetBSD's, so take exactly theirs." 2013-01-22 23:19:35 +00:00
Elliott Hughes
2b47307012 Our strcoll(3) is no different from NetBSD's, so take exactly theirs.
Change-Id: I45251047202a229f9175735ecc23c0ebcda71e8d
2013-01-22 15:10:19 -08:00
Elliott Hughes
547eba0a63 Merge "Avoid overflow in memccpy." 2013-01-22 22:53:54 +00:00
Elliott Hughes
c51cd764a2 Avoid overflow in memccpy.
Just take the upstream NetBSD code.

Bug: http://code.google.com/p/android/issues/detail?id=43078
Change-Id: Ibbbde9d00e8bc6a09c9503aab2b04b4e3d1f98b0
2013-01-22 14:41:23 -08:00
Elliott Hughes
85597e2b59 Merge "Clean up debuggerd-related logging." 2013-01-22 22:37:28 +00:00
Elliott Hughes
7af7895eeb Merge "Use the new non-allocating logging for dlmalloc failures." 2013-01-22 22:26:35 +00:00
Elliott Hughes
ce4cf90d79 Use the new non-allocating logging for dlmalloc failures.
Change-Id: I88afe0201ee5766a295fc5a9e710fba9d6e0d363
2013-01-22 14:24:52 -08:00
Elliott Hughes
6b8e321e61 Clean up debuggerd-related logging.
Bug: 7291287
Change-Id: Ia7aa386e8b75b8058d7d9e707e11b1da7dc62f00
2013-01-22 14:17:14 -08:00
Nick Kralevich
244bee5bb6 Merge "bionic_auxv.h: fix #define conflict" 2013-01-22 21:30:27 +00:00