Commit graph

13 commits

Author SHA1 Message Date
tedbo
ad1ff2fb26 Add mkdtemp() prototype to stdlib.h.
The mkdtemp() function is implemented in libc/stdio/mktemp.c but not
exposed in stdlib.h. This change adds the prototype to stdlib.h.

Change-Id: I5a98650c665d2e45b2cf6ed3382742f7bdc7c88a
2010-11-30 12:45:02 -08:00
David 'Digit' Turner
bb5581ad6e libc: tag missing functions in system headers.
This matches recent changes in the NDK header.
We enclose missing functions in #if 0 .. #endif blocks
with a clear "MISSING" in comments in order to locate
them later.

Change-Id: I87b3a62e777897e75c9243360fb0a82bcc53d9fb
2010-10-09 17:56:55 +02:00
David 'Digit' Turner
50ace4fec5 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
2010-06-22 17:51:41 -07:00
Jing Yu
506b13d910 Remove a gcc-4.5 compilation warning:
bionic/libc/include/../include/stdlib.h: In function 'int grantpt(int)':
bionic/libc/include/../include/stdlib.h:138:23: warning: parameter '__fd' set but not used [-Wunused-but-set-parameter]

By adding __attribute((unused)) to __fd, the warning is gone, and this
attribute is compatible with gcc-4.4.0, gcc-4.3.1 gcc-4.2.1.
There is no any side effect.

Change-Id: I385f0f4da1013ffd1499e391eac9123aafe1f7a5
2010-06-09 13:24:22 -07:00
Colin Cross
6458c49c96 Fix ptsname_r(3) return type to match glibc
The gHardy man pages specify the return type of ptsname_r to be char*, but the
return value to be 0 on success, negative on error and the gHardy stdlib.h
defines extern int ptsname_r(...).

Busybox telnetd fails to run successfully without this change.
2010-01-12 12:58:12 -08:00
Mathias Agopian
5f53a18204 Revert "Add qsort_r() implementation to the C library."
This reverts commit 754c178ae5.

Turns out we don't need it afterall (needed a stable sort anyways).
So, we'll make that change in the dev branch instead.
2009-12-03 16:14:40 -08:00
David 'Digit' Turner
754c178ae5 Add qsort_r() implementation to the C library.
NOTE: This replaces qsort.c with the FreeBSD version. While
      the patch changes the source, it should not alter the
      implementation that should use the exact same algorithm.
2009-12-03 11:40:15 -08:00
The Android Open Source Project
1dc9e472e1 auto import from //depot/cupcake/@135843 2009-03-03 19:28:35 -08:00
The Android Open Source Project
1767f908af auto import from //depot/cupcake/@135843 2009-03-03 18:28:13 -08:00
The Android Open Source Project
e5cc1f386b auto import from //branches/cupcake/...@126645 2009-01-15 16:12:07 -08:00
The Android Open Source Project
6d6c82c7a0 auto import from //branches/cupcake/...@125939 2009-01-09 17:50:54 -08:00
The Android Open Source Project
4e468ed2eb Code drop from //branches/cupcake/...@124589 2008-12-17 18:03:48 -08:00
The Android Open Source Project
a27d2baa0c Initial Contribution 2008-10-21 07:00:00 -07:00