aboutsummaryrefslogtreecommitdiffstats
path: root/libc
Commit message (Collapse)AuthorAgeFilesLines
* Split the shared group data from the shared passwd data.Elliott Hughes2014-12-182-37/+50
| | | | | | | | | | | | | | Found by the toybox id(1) which calls both getpwuid(3) and getgrgid(3) before looking at either result. The use of a shared buffer in this code meant that even on a single thread, the data for any of the passwd functions would be clobbered by the data for any of the group functions (or vice versa). This might seem like an insufficient fix, but POSIX explicitly says (for getpwnam) that the result "might be overwritten by a subsequent call to getpwent(), getpwnam(), or getpwuid()" and likewise for other members of that group, plus equivalent text for the group-related functions. Change-Id: I2272f47e91f72e043fdaf7c169fa9f6978ff4370
* Merge "Sync with upstream for gethnamaddr.c."Yabin Cui2014-12-184-553/+1137
|\
| * Sync with upstream for gethnamaddr.c.Yabin Cui2014-12-174-553/+1137
| | | | | | | | | | Bug: 18566967 Change-Id: I37e7410226b49eec67614e20b2c1d5e3e47817a5
* | Merge "Fix <net/route.h>."Elliott Hughes2014-12-163-2/+46
|\ \ | |/ |/|
| * Fix <net/route.h>.Elliott Hughes2014-12-153-2/+46
| | | | | | | | | | | | | | | | Previously it couldn't be included alone. Also add a header and include guard, and fix its siblings' include guards. Bug: https://code.google.com/p/android/issues/detail?id=82638 Change-Id: I32139a4bda0a6b015508a2319bf4e1a1453345f2
* | Move the generic arm memcmp.S into the generic directory.Elliott Hughes2014-12-157-1/+5
|/ | | | Change-Id: I48e4d14a0dcddbb246edbac6d0329619574ab44d
* Remove arm assembler not referenced from any makefile.Elliott Hughes2014-12-143-1617/+0
| | | | | | | I also suspect that libc/arch-arm/bionic/memcmp.S is supposed to like in the generic directory these days, but this change just removes dead code. Change-Id: I9072488df6e9b7261d79b6014914a0e937cb387b
* Merge "Fix pthread key num calculation."Yabin Cui2014-12-133-8/+25
|\
| * Fix pthread key num calculation.Yabin Cui2014-12-123-8/+25
| | | | | | | | | | Bug: 18723085 Change-Id: Iba2c834b350e4cdba0b2d771b221560a3e5df952
* | Merge "[MIPS] Add sgidefs.h for mips64"Elliott Hughes2014-12-132-1/+1
|\ \ | |/ |/|
| * [MIPS] Add sgidefs.h for mips64Duane Sand2014-12-122-1/+1
| | | | | | | | | | | | | | | | Sgidefs.h is needed by strace. Replaced now-duplicate arch-mips64/include directory by symlink to arch-mips/include. Change-Id: I7808602cfa452eca3ffbdb94903f4c5bdb33efa3
* | Merge "fix runtime issues for scripts"Christopher Ferris2014-12-112-6/+3
|\ \
| * | fix runtime issues for scriptsKyunam Jo2014-12-102-6/+3
| | | | | | | | | | | | | | | | | | | | | | | | now, some script to update kernel-headers is not working. because of wrong variable value and test codes. so this issue is fixed. Change-Id: Iffae9607858cc3c1c58fa24244be217b5a1ab06e
* | | Clean up DNS proxying.Elliott Hughes2014-12-104-117/+79
| |/ |/| | | | | | | | | | | | | | | Remove code duplication and fall back to trying directly if the proxy isn't available. With this, tests still work if netd is dead (perhaps because you've run "adb shell stop", or because you're running on the host). Bug: 18547878 Change-Id: Ia4a9aa18b1fc79e09735107246989fa7fc6c8455
* | Merge "Fix missing symbol for debug malloc."Christopher Ferris2014-12-101-1/+1
|\ \
| * | Fix missing symbol for debug malloc.Christopher Ferris2014-12-101-1/+1
| | | | | | | | | | | | | | | Bug: 18686270 Change-Id: I800a6f0940060218413df652d74aca91f6a339f8
* | | Merge "Fix arm64 clone stack handling."Elliott Hughes2014-12-102-10/+13
|\ \ \
| * | | Fix arm64 clone stack handling.Elliott Hughes2014-12-102-10/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Make sure we adjust the stack pointer so a signal can't overwrite data. Bug: 15195265 Change-Id: I5ab9469a82cb214c32f40a713268a1ab74a4c6fa
* | | | Merge "Use machine/timespec.h to separate timespec definition."Yabin Cui2014-12-105-11/+55
|\ \ \ \ | |/ / / |/| | |
| * | | Use machine/timespec.h to separate timespec definition.Yabin Cui2014-12-105-11/+55
| |/ / | | | | | | | | | Bug: 18627763 Change-Id: Ib1c406320f0ecc3705d19183a48f986cdf57c279
* | | Merge "Use the stmdb instead of str to save the fn/arg"Elliott Hughes2014-12-101-4/+2
|\ \ \ | |_|/ |/| |
| * | Use the stmdb instead of str to save the fn/argJiangli Yuan2014-12-101-4/+2
| |/ | | | | | | | | | | | | | | | | | | Directly save data into stack without properly adjustment of stack point is dangous. For example, if a signal comes, kernel will put sigframe into userspace's stack, which will overwrite the saved data if sp is not adjusted properly. Bug: 15195265 Change-Id: Iea0cadfd3b94d50cf40252ad52fe5950811b9192 Signed-off-by: Jiangli Yuan <a6808c@motorola.com>
* | Fix ptsname(3) and ttyname(3) to use TLS.Elliott Hughes2014-12-094-7/+14
| | | | | | | | | | | | Be safe by default. Change-Id: I6c4a3f1fd4eee3a651b3162ce95b7e873de57521
* | Move BSD stuff together in <sys/endian.h>.Elliott Hughes2014-12-091-31/+24
|/ | | | Change-Id: I8bb511840f3cd98d5008034e405d82e923bd3203
* <net/route.h> should include IPv6 too.Elliott Hughes2014-12-091-0/+1
| | | | Change-Id: I866097d8468aa8f326117d072444ebbc2a690719
* Sync <net/if_types.h> with upstream.Elliott Hughes2014-12-091-2/+3
| | | | Change-Id: I2c2ca47f5a21b78754c03deb3e9467ab79d9d033
* Merge "support _POSIX_REALTIME_SIGNALS"Yabin Cui2014-12-0913-1/+248
|\
| * support _POSIX_REALTIME_SIGNALSYabin Cui2014-12-0813-1/+248
| | | | | | | | | | Bug: 18489947 Change-Id: I2e834d68bc10ca5fc7ebde047b517a3074179475
* | Merge "Change _POSIX_CPUTIME macro to make it compitable with glibc."Yabin Cui2014-12-092-4/+12
|\ \
| * | Change _POSIX_CPUTIME macro to make it compitable with glibc.Yabin Cui2014-12-092-4/+12
| | | | | | | | | | | | Change-Id: I7a8dbb74bd622693c9fef60bd779687207517b7d
* | | Simplify our endian.h implementation.Elliott Hughes2014-12-087-472/+21
| | | | | | | | | | | | | | | | | | | | | We can rely on the compiler's builtins. Tested on arm, arm64, mips, x86, and x86-64. Change-Id: I0f774ed7e85b3c791a3178d8ef17c6500e6a9ace
* | | Merge mips setjmp/longjmp family.Elliott Hughes2014-12-089-773/+287
| | | | | | | | | | | | | | | Bug: 16918359 Change-Id: I9033a7d178d431ddb09f1cfa6e4bf95ae02346e9
* | | Switch arch-mips64/include/machine to a symlink.Elliott Hughes2014-12-087-659/+1
| | | | | | | | | | | | | | | | | | | | | Imagination already did the work to make the contents of these directories identical. Let's take advantage of that fact. Change-Id: Ib101ba39041fb500c9c618fa2020e72aa2ccd9c2
* | | Use 64-bit units in the aarch64 setjmp implementation.Elliott Hughes2014-12-081-50/+39
| | | | | | | | | | | | | | | | | | | | | The use of 32-bit units for 64-bit stores and loads was driving me crazy. Bug: 16918359 Change-Id: Ifb73aad8f8985a2adfcf5913b783ad9424f23e06
* | | Switch arm and arm64 over to the x86 style of jmpbuf.Elliott Hughes2014-12-082-45/+25
| | | | | | | | | | | | | | | | | | | | | | | | Specifically, use the argument to sigsetjmp as a flag in the buffer to indicate whether or not the signal mask is valid. Bug: 16918359 Change-Id: I5bb1f1220f14c105c6bc57e0c28c1dc366d1438f
* | | Merge "Fix signal mask save/restore for x86-64."Elliott Hughes2014-12-081-10/+14
|\ \ \ | |/ / |/| |
| * | Fix signal mask save/restore for x86-64.Elliott Hughes2014-12-081-10/+14
| | | | | | | | | | | | | | | Bug: 16918359 Change-Id: I30bf61e7d5f1c21daa3a1a21d361e98d77220bf3
* | | Fix signal mask save/restore for arm64.Elliott Hughes2014-12-062-25/+20
|/ / | | | | | | | | Bug: 16918359 Change-Id: Ieb15f7f1658f5accee05665b72ba17831a80ea9d
* | Clean up the x86-64 and x86 setjmp families.Elliott Hughes2014-12-059-468/+181
| | | | | | | | | | Bug: 16918359 Change-Id: Ic8ca0af9ea99636bc71f19d46071f1cea6eef982
* | Clean up arm setjmp family.Elliott Hughes2014-12-055-314/+146
| | | | | | | | | | Bug: 16918359 Change-Id: I9b986bdbdbaefe9d9896a820ee8cfe860adfe5c5
* | Clean up the arm64 setjmp.Elliott Hughes2014-12-057-314/+148
| | | | | | | | | | | | | | | | Note that this doesn't address the fact that we don't save/restore the real-time signals. But it does let us pass the tests we currently fail. Bug: 16918359 Change-Id: I063a6926164289a71026a412da7f5dd2ca9a74b3
* | Merge "Add cache related sysconf queries"Tao Bao2014-12-052-0/+34
|\ \
| * | Add cache related sysconf queriesTao Bao2014-12-042-0/+34
| | | | | | | | | | | | | | | | | | | | | | | | Several cache related queries are added, such as _SC_LEVEL1_DCACHE_LINESIZE, _SC_LEVEL1_DCACHE_SIZE and etc. For the moment, we always return 0 for these queries. Change-Id: I36f67af8128672d8c1eef49d6f2431cca5a94719
* | | Merge "Restore symbols from <arpa/nameser.h>."Elliott Hughes2014-12-041-74/+45
|\ \ \
| * | | Restore symbols from <arpa/nameser.h>.Elliott Hughes2014-12-041-74/+45
| | | | | | | | | | | | | | | | | | | | | | | | Bug: 18627252 Bug: https://code.google.com/p/android/issues/detail?id=81690 Change-Id: I45b6c09cf2b5aabb80900e267d27cc0ec93d4dd8
* | | | Merge "implement posix_madvise"Yabin Cui2014-12-044-1/+52
|\ \ \ \ | |/ / / |/| | |
| * | | implement posix_madviseYabin Cui2014-12-044-1/+52
| | | | | | | | | | | | | | | | | | | | Bug: 18472477 Change-Id: I8183de6c281acf69ed5f7f88351b056b9827b162
* | | | Make the missing symbols script more useful.Elliott Hughes2014-12-041-12/+17
|/ / / | | | | | | | | | | | | | | | | | | | | | | | | If something's in POSIX, we don't need to show it in the glibc list. If something's not implemented by glibc, we don't need to show it in the POSIX list (because it's probably either a macro or obsolete). Change-Id: Ied0f8d97d3fffb280c22e9cdf6782430d776c02f
* | | Code using neon uses ARCH_ARM_HAVE_NEON.Elliott Hughes2014-12-031-16/+0
| | | | | | | | | | | | | | | Bug: 18556103 Change-Id: Ia8674dda223f81d616d15ee47b402ab4a3f98079
* | | Remove __ARM_HAVE_VFP.Elliott Hughes2014-12-033-18/+0
| | | | | | | | | | | | | | | Bug: 18556103 Change-Id: I6d4cc6a1b359ad2df1ce6687fd26f392059f6efd