diff options
| author | Paul Eggert | 2011-04-08 14:53:30 -0700 |
|---|---|---|
| committer | Paul Eggert | 2011-04-08 14:53:30 -0700 |
| commit | 7ec98caf7757bbf462d91a5cebd440cf12cc5816 (patch) | |
| tree | a06f12700c55c0a932163ff80c6c3d01883a9c36 /lib/stdlib.in.h | |
| parent | 70476b54414db1be5261c71073fc991eab5cd34a (diff) | |
| download | emacs-7ec98caf7757bbf462d91a5cebd440cf12cc5816.tar.gz emacs-7ec98caf7757bbf462d91a5cebd440cf12cc5816.zip | |
Update from gnulib.
Diffstat (limited to 'lib/stdlib.in.h')
| -rw-r--r-- | lib/stdlib.in.h | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/lib/stdlib.in.h b/lib/stdlib.in.h index 2697a4bd1db..b9ada2cd1a8 100644 --- a/lib/stdlib.in.h +++ b/lib/stdlib.in.h | |||
| @@ -255,9 +255,14 @@ _GL_WARN_ON_USE (ptsname, "grantpt is not portable - " | |||
| 255 | # endif | 255 | # endif |
| 256 | #endif | 256 | #endif |
| 257 | 257 | ||
| 258 | /* If _GL_USE_STDLIB_ALLOC is nonzero, the including module does not | ||
| 259 | rely on GNU or POSIX semantics for malloc and realloc (for example, | ||
| 260 | by never specifying a zero size), so it does not need malloc or | ||
| 261 | realloc to be redefined. */ | ||
| 258 | #if @GNULIB_MALLOC_POSIX@ | 262 | #if @GNULIB_MALLOC_POSIX@ |
| 259 | # if @REPLACE_MALLOC@ | 263 | # if @REPLACE_MALLOC@ |
| 260 | # if !(defined __cplusplus && defined GNULIB_NAMESPACE) | 264 | # if !((defined __cplusplus && defined GNULIB_NAMESPACE) \ |
| 265 | || _GL_USE_STDLIB_ALLOC) | ||
| 261 | # undef malloc | 266 | # undef malloc |
| 262 | # define malloc rpl_malloc | 267 | # define malloc rpl_malloc |
| 263 | # endif | 268 | # endif |
| @@ -267,7 +272,7 @@ _GL_CXXALIAS_RPL (malloc, void *, (size_t size)); | |||
| 267 | _GL_CXXALIAS_SYS (malloc, void *, (size_t size)); | 272 | _GL_CXXALIAS_SYS (malloc, void *, (size_t size)); |
| 268 | # endif | 273 | # endif |
| 269 | _GL_CXXALIASWARN (malloc); | 274 | _GL_CXXALIASWARN (malloc); |
| 270 | #elif defined GNULIB_POSIXCHECK | 275 | #elif defined GNULIB_POSIXCHECK && !_GL_USE_STDLIB_ALLOC |
| 271 | # undef malloc | 276 | # undef malloc |
| 272 | /* Assume malloc is always declared. */ | 277 | /* Assume malloc is always declared. */ |
| 273 | _GL_WARN_ON_USE (malloc, "malloc is not POSIX compliant everywhere - " | 278 | _GL_WARN_ON_USE (malloc, "malloc is not POSIX compliant everywhere - " |
| @@ -531,7 +536,8 @@ _GL_WARN_ON_USE (setstate_r, "setstate_r is unportable - " | |||
| 531 | 536 | ||
| 532 | #if @GNULIB_REALLOC_POSIX@ | 537 | #if @GNULIB_REALLOC_POSIX@ |
| 533 | # if @REPLACE_REALLOC@ | 538 | # if @REPLACE_REALLOC@ |
| 534 | # if !(defined __cplusplus && defined GNULIB_NAMESPACE) | 539 | # if !((defined __cplusplus && defined GNULIB_NAMESPACE) \ |
| 540 | || _GL_USE_STDLIB_ALLOC) | ||
| 535 | # undef realloc | 541 | # undef realloc |
| 536 | # define realloc rpl_realloc | 542 | # define realloc rpl_realloc |
| 537 | # endif | 543 | # endif |
| @@ -541,7 +547,7 @@ _GL_CXXALIAS_RPL (realloc, void *, (void *ptr, size_t size)); | |||
| 541 | _GL_CXXALIAS_SYS (realloc, void *, (void *ptr, size_t size)); | 547 | _GL_CXXALIAS_SYS (realloc, void *, (void *ptr, size_t size)); |
| 542 | # endif | 548 | # endif |
| 543 | _GL_CXXALIASWARN (realloc); | 549 | _GL_CXXALIASWARN (realloc); |
| 544 | #elif defined GNULIB_POSIXCHECK | 550 | #elif defined GNULIB_POSIXCHECK && !_GL_USE_STDLIB_ALLOC |
| 545 | # undef realloc | 551 | # undef realloc |
| 546 | /* Assume realloc is always declared. */ | 552 | /* Assume realloc is always declared. */ |
| 547 | _GL_WARN_ON_USE (realloc, "realloc is not POSIX compliant everywhere - " | 553 | _GL_WARN_ON_USE (realloc, "realloc is not POSIX compliant everywhere - " |