summaryrefslogtreecommitdiff
path: root/lib/libc/stdlib
AgeCommit message (Collapse)Author
2013-06-05Move _Exit() from the exit() manpage to the _exit() manpage, as it'sPhilip Guenther
just an alias of the latter. ok matthew@ tedu@
2013-06-05Use the fancy .In macro for includes. From Jan Klemkow. ok jmc schwarzeTed Unangst
2013-06-02Two small cleanups to atexit: remove unneeded __atexit_invalid, andMatthew Dempsky
move the call_depth decrement so it happens unconditionally and can still return to 0 when called with dso!=NULL. ok millert
2013-04-17surround the error strings with quotes to clarify exactly which stringsTed Unangst
the function is going to return.
2013-04-17the tiniest of style tweaksTed Unangst
2013-04-17add some prototypes, casts, includes, parenthesis, and whatnot toTed Unangst
silence some warnings.
2013-04-05- Add comments regarding copies of these files also in libexec/ld.soKurt Miller
okay guenther@
2013-04-03Update a comment about standards requirementsPhilip Guenther
2013-03-28Switch libc and libm to use strong aliases rather than weak aliasesMartynas Venckus
where appropriate. Among other things makes the symbols consistent across all architectures (notably where ldbl mantissa is 53 bits). While at it, kill unused LINTLIBRARY/PROTOLIB1 cruft which was there to trick lint into recording the right prototypes for aliased functions. Most of the work done at the awesome n2k13 hackathon. Agreed by kettenis@, guenther@, matthew@.
2013-03-15threadsafe random().Ted Unangst
reported by ajacoutot and (much earlier, sorry) by Alexey Suslikov
2013-01-15Don't pull <math.h> just because it can return HUGE_VAL in theMartynas Venckus
corner cases. OK millert@.
2012-12-22Fix bug in random offset introduced in rev 1.143; random range wasOtto Moerbeek
expanded, but not enough due to precedence error. Spotted by Thorsten Glaser.
2012-12-05Remove excessive sys/cdefs.h inclusionTheo de Raadt
ok guenther millert kettenis
2012-12-05no need for .Pp before lists;Jason McIntyre
2012-12-04Rewritten posix_openpt manual that doesn't include any of the POSIXTodd C. Miller
text. OK deraadt@
2012-12-04Use "path name" not "pathname".Todd C. Miller
2012-12-03Simple emulation of POSIX pty APIs posix_openpt(), ptsname(),Todd C. Miller
grantpt() and unlockpt() using /dev/ptm. Man pages from FreeBSD. OK kettenis@ deraadt@ beck@ ajacoutot@ naddy@
2012-11-18Ensure that the base provided to strtol(3) is between 2 and 36 inclusive,Joel Sing
or the special value of 0. ok deraadt@ otto@
2012-11-10Per POSIX, fix raise() and abort() to send the signal to the current thread.Philip Guenthe
Should make coredumps from abort() easier to debug too. ok kurt@
2012-11-02Add a new malloc option 'U' => "Free unmap" that does the guarding/Damien Miller
unmapping of freed allocations without disabling chunk randomisation like the "Freeguard" ('F') option does. Make security 'S' option use 'U' and not 'F'. Rationale: guarding with no chunk randomisation is great for debugging use-after-free, but chunk randomisation offers better defence against "heap feng shui" style attacks that depend on carefully constructing a particular heap layout so we should leave this enabled when requesting security options.
2012-09-23Make setenv(3) consistent with unsetenv(3), giving EINVAL if passedJeremy Evans
an empty name, NULL pointer, or a name containing an '=' character. OK millert@, guenther@
2012-09-16remove some wacky Xo/Xc;Jason McIntyre
2012-09-15remove tahoe-specific makefile machinery, no such hardware is known to beMiod Vallat
in working condition anymore (assuming there would be interest in running on it).
2012-09-15Document that strtod functions accept INF, NAN, NAN(). From Michal Mazurek.Martynas Venckus
2012-09-13specify the bounds of the dst to strlcat (both values were static andTheo de Raadt
equal, but it is more correct) from Michal Mazurek
2012-09-13Fix precedence bug (& has lower precedence than !=).Paul Irofti
Okay otto@. Found by Michal Mazurek <akfaew at jasminek dot net>, thanks!
2012-09-04remove lint leftovers; ok guenther@Okan Demirmen
2012-07-09use PAGE_SHIFT instead of PGSHIFT, in preperation for futureTheo de Raadt
param.h symbol reduction. ok guenther
2012-07-08Zap extra spaces from function pointer argumentsPhilip Guenthe
Pointed out by Joachim Schipper (joachim at joachimschipper.nl)
2012-07-08Describe tdelete()'s return value correctly and update the related CAVEATPhilip Guenthe
Based on a note from Steffen Daode Nurpmeso (sdaoden at googlemail.com) ok jmc@
2012-06-26after a talk with ariane, use MAP_FIXED for mquery to avoid the cost ofTed Unangst
scanning for free space if the hint isn't available. also, on further inspection, this will prevent pmap_prefer from "improving" our hint.
2012-06-22two changes which should improve realloc. first, fix zapcacheregion toTed Unangst
clear out the entire requested area, not just a perfect fit. second, use mquery to check for room to avoid getting an address we don't like and having to send it back.
2012-06-20two small fixes to free page cache. first, we need two nibbles of randomTed Unangst
in order to span the the entire cache. second, on free use the same offset to put things in the cache instead of always starting at zero. ok otto
2012-06-18Support larger-than-page-alignment requests in posix_memalign() byMatthew Dempsky
overallocating and then releasing unneeded memory pages. ok otto
2012-06-02Update STANDARDS section for a few <stdlib.h> functionsPhilip Guenthe
Update SYNOPSIS for setkey() to show it's in <stdlib.h> ok jmc@, millert@
2012-06-01Improve standards conformance: ecvt(), fcvt(), gcvt(), mktemp(), ttyslot(),Philip Guenthe
and valloc() are not in the current version, while posix_memalign() mkstemp(), and mkdtemp() are, and setstate()'s argument has lost a bogus 'const'. ok millert@ jmc@ espie@ kettenis@; ports build testing by naddy@
2012-04-12alloca is NOT machine dependent; it has exactly the sameTheo de Raadt
effective result. its use is NOT discouraged -- it is not common, but when you need it, there is nothing else that will do.
2012-03-21Fix a bug where random() always returns 0 when srandom() is seededTodd C. Miller
with 0. Use 1 and not 0 as the first element of the state array, similar to what glibc does. OK nicm@
2012-02-29- Test for the retrieved page address not being NULL. This turns free((void*)1)Otto Moerbeek
into an bogus pointer error instead of a segfault. - Document that we use the assumption that a non-MAP_FIXED mmap() with hint 0 never returns NULL.
2012-02-06Revert previous diff as it resulted in the wrong return code whenPhilip Guenthe
the last node is deleted. Instead, resolve the Coverity warning by returning (node *)1 when you delete the root node. based an idea from millert@. ok otto@
2011-11-17Complete the HISTORY of all syscalls that exist since Version 1 AT&T UNIX.Ingo Schwarze
All facts from http://minnie.tuhs.org/cgi-bin/utree.pl, checked by sobrado@. Feedback and ok jmc@ jmc@ (sic, Jason checked and ok'ed this twice).
2011-10-06Make struct chunk_info a variable sized struct, wasting lessOtto Moerbeek
space for meta data by only allocating space actually needed for the bitmap (modulo alignment requirements). ok deraadt@
2011-09-03some minor tweaks;Jason McIntyre
2011-09-03make -column lists pretty again;Jason McIntyre
specifically, rewrite them to permit some markup in the column headers, and use "Ta" instead of literal tabs; mandoc does not currently match groff 100%, but a mandoc fix may be some time off, and we've gone enough releases with poorly formatting column lists. in some cases i have rewritten the lists as -tag, where -column made little sense.
2011-08-30in column lists, enforce the following ordering:Jason McIntyre
.Bl -column header1 header2 ... <Bl flags> mixing things up confuses mandoc, and adding flags in can screw up the list. this hopefully just makes things a bit safer (and more consistent). (one more bit of work left and all column lists should format how we want)
2011-07-24occured -> occurred;Jason McIntyre
2011-07-24Recent Single Unix will malloc memory if the second argument of realpath()Miod Vallat
is NULL, and third-party software is starting to rely upon this. Adapted from FreeBSD via Jona Joachim (jaj ; hcl-club , .lu), with minor tweaks from nicm@ and yours truly.
2011-07-22Show (in the example) that < and > can be used multiple times; ok jmc@Otto Moerbeek
jasper@
2011-07-21- add a MALLOC_OPTIONS section header. the content is already there, but havingJasper Lievisse Adriaanse
a section will help people looking for just the MALLOC_OPTIONS. ok otto@ jmc@
2011-07-12on malloc flag S, set cache size to 0; will catch even moreOtto Moerbeek
use-after-free bugs; ok krw@ dlg@ pirofti@