Remove expired dns cache entries before removing oldest

A suggestion how to make a smarter delete function when the cache
is full. First look through the entire cache and remove all entries
which have expired. If none use the old solution and just remove
the last entry in the MRU list.

Change-Id: I5f997ab35290a55dc6e1ddf37d725759edf83d36
[MIPS] Fix the warning originating from the kernel header signal.h.
This is a clean header generated from the corresponding change in
external/kernel-headers repository. (CL 35760)
Merge "[MIPS] Fix the warning originating from the kernel header signal.h. This is a clean header generated from the corresponding change in external/kernel-headers repository. (CL 35760)"
Add the posix_memalign(3) function to bionic

The posix_memalign(3) function is very similar to the traditional
memalign(3) function, but with better error reporting and a guarantee
that the memory it allocates can be freed.  In bionic, memalign(3)
allocated memory can be freed, so posix_memalign(3) is just a wrapper
around memalign(3).

Change-Id: I62ee908aa5ba6b887d8446a00d8298d080a6a299
Merge branch 'master' of https://android.googlesource.com/platform/bionic

Change-Id: I510234e5daec71bf01eb1f7dc56b6b02ba0acc7e
Update s_fabsl.c to upstream head.

Bug: http://code.google.com/p/android/issues/detail?id=29539
Change-Id: I843dcfcbfe49e8e9f43c49aae6ade1edb57a3053
Merge "Update s_fabsl.c to upstream head."
fnmatch.c: Update to version in OpenBSD HEAD

Upgrade fnmatch.c from OpenBSD version 1.13 to 1.16.
This is needed primarily to address CVE-2011-0419.

This is a straight copy from upstream's version at
http://www.openbsd.org/cgi-bin/cvsweb/src/lib/libc/gen/fnmatch.c and
incorporates the following changes:

Revision 1.16:
New fnmatch(3) implementation which is not recursive.
Written and provided under BSD licence by William A. Rowe Jr.
Originally released in Apache APR-1.4.5.
Merged class matching code from r1.14 and PATH_MAX check from r1.15.
ok miod millert

Revision 1.15:
Put a limit on recursion during matching, and reject input of size greater
or equal PATH_MAX. Based on similar fix made in NetBSD.
ok miod@ millert@

Revision 1.14:
POSIX character class support for fnmatch(3) and glob(3).  OK deraadt@

Version 1.14 introduced charclasses.h, which we copy unmodified
from upstream version 1.1.
http://www.openbsd.org/cgi-bin/cvsweb/src/lib/libc/gen/charclass.h

Bug: 3435120
Change-Id: I3da25d3f6670d96484403bb6f45a1f84506782e0
MIPS support to libm, libdl and libthread_db

Change-Id: I9106721af7fe0cd45df82976250db0d300a20117
Signed-off-by: Raghu Gandham <raghu@mips.com>
Merge "MIPS support to libm, libdl and libthread_db"
Adjust memcpy for ARM Cortex A9 cache line size

ARM Cortex A8 use 64 bytes and ARM Cortex A9 use 32 bytes cache line
size.

The following patch:
  Adds code to adjust memcpy cache line size to match A9 cache line
  size.
  Adds a flag to select between 32 bytes and 64 bytes cache line
  size.

  Copyright (C) ST-Ericsson SA 2010
    Modified neon implementation to fit Cortex A9 cache line size
    Author: Henrik Smiding henrik.smiding@stericsson.com for
            ST-Ericsson.

Change-Id: I8a55946bfb074e6ec0a14805ed65f73fcd0984a3
Signed-off-by: Christian Bejram <christian.bejram@stericsson.com>
Merge "Adjust memcpy for ARM Cortex A9 cache line size"
Merge "Remove expired dns cache entries before removing oldest"
bionic: fix integer overflows in chk_malloc(), leak_malloc(), and leak_memalign()

The allocation size in chk_malloc(), leak_malloc(), and leak_memalign()
functions may be rounded up to a small value, leading to buffer overflows.
The code only runs in debugging mode.

This patch complements commit 6f04a0f4 (CVE-2009-0607).

Change-Id: Id899bcd2bcd2ea2205e5753c433390710032dc83
Signed-off-by: Xi Wang <xi.wang@gmail.com>
Merge "bionic: fix integer overflows in chk_malloc(), leak_malloc(), and leak_memalign()"
Revert "msm7627A: Enable 7627A specific memcpy routine"

This reverts commit 8924110e07ed7e2190f2d298d790bbc437deefd5.
Merge branch 'master' of https://android.googlesource.com/platform/bionic

Conflicts:
	libc/Android.mk

Change-Id: I333a90ddf16ea7354b2a44ee6f46463e55b893a8
Let pthread_create fail if schedparam can't be set

The creation of a thread succeeds even if the requested scheduling
parameters can not be set. This is not POSIX compliant, and even
worse, it leads to a wrong behavior. Let pthread_create() fail in this
case.

Change-Id: Ice66e2a720975c6bde9fe86c2cf8f649533a169c
Signed-off-by: Christian Bejram <christian.bejram@stericsson.com>
Merge "Let pthread_create fail if schedparam can't be set"
Cherry-pick "generate PIC code".

Change-Id: I7d5f2e5663df263493f65e364c959e663fc4d13a