summaryrefslogtreecommitdiff
path: root/src/lib/libc/stdlib (follow)
Commit message (Collapse)AuthorAgeFilesLines
...
* Now that we use an array of u_short for the chunk bitmap change a fewotto2011-04-301-5/+5
| | | | 1UL to 1U.
* More efficient scanning for free chunks while not losing any randomization;otto2011-04-301-21/+25
| | | | thanks to all testers.
* Tweak the description of the optional parts around =. Found this in myotto2011-04-271-5/+7
| | | | tree, no idea where it came from; ok millert@ jmc@
* tweak for clarity, ok millert@, jmc@espie2011-03-211-4/+4
|
* wrong type for variable; spotted by christian.siebert@cs.tu-chemnitz.dederaadt2011-03-061-3/+3
| | | | ok guenther
* Fix PR 6267: recheck POSIXLY_CORRECT each time getopt_long() starts a newguenther2011-03-053-44/+16
| | | | | | | | argv and don't suppress the handling of leading '-' in optstring when POSIXLY_CORRECT is set. Based on patch from Eric Blake. ok and manpage update from millert@, manpage ok jmc@
* Fix __cxa_finalize() so that calling __cxa_finalize(NULL) properlymatthew2011-03-021-2/+2
| | | | | | invokes handlers registered with __cxa_atexit(). "seems right" deraadt@
* Correctly escape a literal colon in an enclosure;schwarze2011-01-241-3/+3
| | | | the \: roff escape is an optional line break.
* superceded -> superseded;jmc2011-01-141-3/+3
|
* avoid pointer arithmetic on void *dhill2010-12-161-5/+5
| | | | | | tested for a while by me. ok otto@
* involes -> involves; from Carlos Alberto Pereira Gomesjmc2010-11-301-1/+1
|
* print the pointer value that caused the error (if available); okotto2010-10-211-47/+54
| | | | deraadt@ nicm@ (on an earlier version)
* Make gcvt() better match printf("%g") behavior, it now passes regress.millert2010-09-251-11/+23
| | | | OK deraadt@
* more wacky macro fixing;jmc2010-09-191-37/+37
|
* Check for duplicate variables in the environment when setting a valuemillert2010-08-232-11/+24
| | | | via setenv() or putenv(). OK miod@
* Sync hcreate(3) with NetBSD, adding some caveats.ray2010-07-281-12/+67
| | | | OK jmc
* getopt_long.c replaced getopt.c 6+ years ago; we can retireblambert2010-07-221-7/+1
| | | | | | the REPLACE_GETOPT macro, at long last ok millert@
* Document new unsetenv() error returns.naddy2010-07-061-2/+8
| | | | From Nicolas Legrand <nlegrand@ethelred.fr>; ok jmc@
* Make unsetenv(NULL) and unsetenv("") give EINVAL, per POSIX. ok deraadt@naddy2010-06-291-1/+5
|
* oops - forgot to check for trailing whitespace;jmc2010-05-261-2/+2
|
* reword the 'D' dump bit to make it clear that the malloc.out file needsthib2010-05-261-4/+5
| | | | | | | to exist before exit for malloc to dump stats in it. tweaks from jmc@ ok otto@,jmc@
* tweak previous;jmc2010-05-191-2/+2
|
* add posix_madvise, posix_memalign, strndup, and strnlen. mostly fromtedu2010-05-184-8/+128
| | | | | brad and millert, with hints from guenther, jmc, and otto I think. ok previous.
* - nuke some unneeded Pp; from kristapsjmc2010-04-071-6/+3
| | | | - small tweak while here
* WARNINGS -> CAVEATS, and a little neccessary cleanup;jmc2010-04-012-24/+24
|
* It's unsetenv() that doesn't like `=' in the argument, not putenv().kili2010-03-101-3/+3
| | | | ok millert@
* Use size_t in appropriate places; fixes sorting of big arrays;otto2010-02-081-9/+10
| | | | | after the diff was written, I made it similar to the freebsd fix of the same code; pr6287 ok millert@ guenther@
* use size_t to index arrays; avoids big array bugs; ok millert@ guenther@otto2010-02-081-1/+1
|
* Use MACHINE_CPU instead of MACHINE_ARCH to pick the correct machine dependentmiod2010-02-031-9/+9
| | | | | | | files or directories when applicable. The inspiration and name of MACHINE_CPU come from NetBSD, although the way to provide it to Makefiles is completely different. ok kettenis@
* stucture -> structure;jmc2010-01-251-3/+3
|
* New options 'S', as a shorthand for the options most suitable as anotto2010-01-132-3/+9
| | | | extra safeguard (FGJ). Idea from deraadt@; ok deraadt@ dlg@
* save calls to arc4random() by using a nibble at a time; not becauseotto2009-12-161-24/+27
| | | | | arc4random() is slow, but it induces getpid() calls; also saves a bit on stirring efforts
* Make userland malloc use __LDPGSZ granularity on mips, regardless of themiod2009-12-071-1/+3
| | | | actual kernel page size.
* Switch the chunk_info lists to doubly-linked lists and use the queueotto2009-11-271-51/+34
| | | | | | macros for them. Avoids walking the lists and greatly enhances speed of freeing chunks in reverse or random order at the cost of a little space. Suggested by Fabien Romano and Jonathan Armani; ok djm@
* Don't forget to fill region from the cache with junk if needed in one case;otto2009-11-271-1/+3
| | | | from Fabien Romano and Jonathan Armani
* No need to clear a mmapped region; from Fabien Romano and Jonathanotto2009-11-271-2/+1
| | | | Armani
* permit -DMALLOC_STATS to compile againtodd2009-11-021-2/+2
| | | | | noticed by Jonathan Armani & Fabien Romano ugh+ok otto@
* rcsid[] and sccsid[] and copyright[] are essentially unmaintained (andderaadt2009-10-271-5/+1
| | | | | | | unmaintainable). these days, people use source. these id's do not provide any benefit, and do hurt the small install media (the 33,000 line diff is essentially mechanical) ok with the idea millert, ok dms
* Check mmap return value against MAP_FAILED not NULL.pirofti2009-10-201-2/+2
| | | | Okay deraadt@, otto@.
* teach gdtoa & its subroutines that malloc can fail; in which casemartynas2009-10-162-2/+6
| | | | | | ecvt, fcvt, gcvt, *printf, strtof, strtod, strtold act per ieee 1003.1. after these massive changes, remove unused files which would not work now. reported by Maksymilian Arciemowicz; ok theo
* rewrite the history section, prompted by Paul Stoeber; ok deraadt@ jmc@otto2009-10-101-25/+28
|
* abs conforms c99 -> imaxabs conforms c99. ok millert@martynas2009-06-211-3/+3
|
* quieten compiler by converting pointers to uintptr_t before truncating themderaadt2009-06-081-5/+5
| | | | | to u_int32_t to do integer math with (in a situation where that is legit) ok otto millert
* Don't assume that we can overwrite strings in the environment.millert2009-06-041-1/+3
| | | | | Someone may have passed a read-only string to putenv() (I'm looking at you cron!).
* Make putenv(), setenv() and unsetenv() standards compliant. Themillert2009-06-035-86/+117
| | | | | | standard explicitly disallows passing setenv a name with a '=' in it but historic BSD behavior is to allow this but to ignore the '=' and anything after it.
* document that no leading whitespace is permitted between the option andokan2009-04-121-3/+5
| | | | | | argument if the argument is deemed to be optional ('::'). feedback and ok jmc@ and millert@
* kill whitespace at eol;jmc2009-02-131-2/+2
|
* decribe 'F' better and mention flags are debugging aids; ok tedu@ jmc@otto2009-02-131-8/+10
|
* correct function definitions; from Markus Bergkvistjmc2009-02-101-4/+4
|
* reintroduce extra malloc protections, but avoiding the use ofdjm2009-01-031-164/+229
| | | | | | PAGE_(SIZE|SHIFT|MASK) defines that evaluate to variables on the sparc architecture; ok otto@ tested on my reanimated ss20