summaryrefslogtreecommitdiff
path: root/lib
AgeCommit message (Collapse)Author
2010-01-19Better ERRORS section info; from Tim van der Molen. POSIX documentsTodd C. Miller
other common errno values for opendir() whereas we just point the user to open() et al. OK jmc@
2010-01-19Leave errno as-is if fstat(2) fails instead of masking the realTodd C. Miller
errno with ENOTDIR. From Tim van der Molen.
2010-01-15Keep in memory whether the socket is writable. This way sio_revents()Alexandre Ratchov
can return POLLOUT (if requested), even the handle was not writable when sio_pollfd() was called but become writable somewhere in the code path of sio_revents(). This should improve stability of programs using very small buffers.
2010-01-15Add support to sysconf(3) for the variables _SC_NPROCESSORS_CONF andStuart Henderson
_SC_NPROCESSORS_ONLN, implemented by AIX/Tru64/Solaris/Linux/SCO/FreeBSD/NetBSD. Bump libc minor. From Brad, ok deraadt@ guenther@
2010-01-14Restore an if that got lost in the update.Nicholas Marriott
Fixes problems with editors/joe reported by benoit@.
2010-01-14Document hw.ncpufound and HW_NCPUFOUND.Philip Guenthe
Document the interpretation of the third and fourth levels of KERN_FILE2. Document that KERN_FILE and KERN_PROC are deprecated in favor of KERN_FILE2 and KERN_PROC2. ok and tweaks jmc@
2010-01-13New options 'S', as a shorthand for the options most suitable as anOtto Moerbeek
extra safeguard (FGJ). Idea from deraadt@; ok deraadt@ dlg@
2010-01-13If a process receives two different signals while in readpassphrase, onlyDarren Tucker
the most recent one will be stored for later re-delivery. When the signal handlers are restored, all except the most recent signal will be lost. Replace the single variable with an array so signals are not lost. ok deraadt@
2010-01-12Update to ncurses 5.7, with local changes reapplied.Nicholas Marriott
This is around eight years worth of changes (previously we were around ncurses 5.2), too many to list - many bug fixes and also a few new functions. A major bump for libcurses, libpanel, libform and libmenu. ok deraadt
2010-01-12the comment is right, this can indeed go away.Jasper Lievisse Adriaanse
it's unused inside libkvm, and nothing else is allowed to use it. ok guenther@ "sure" deraadt@
2010-01-11encourage use of setreseuid(), and warn there are other privs; ok henningTheo de Raadt
2010-01-10Reimplement kvm_getproc2()'s support for reading crash dumps andPhilip Guenthe
/dev/mem to be direct instead of going through kvm_getprocs(), as that function is going to get more an more broken as we move stuff from struct proc to struct process for rthreads. To minimize the code copying, put the common logic of filling in a kinfo_proc2 structure into a macro FILL_KPROC2() in <sys/sysctl.h> for use from both the kernel and user-space. This also hides the KERN_PROC #define behind "#if defined(_KERNEL)||defined(_LIBKVM)", as it's deprecated. Positive feedback from millert and blambert; so committing to unblock further rthreads work.
2010-01-10Fix evsignal_del()'s use of sigaction(): fill in a sigaction structPhilip Guenthe
and pass a pointer to that instead of passing SIG_DFL directly. (Probably the result of a bad signal()-->sigaction() translation...) ok deraadt@, nicm@, miod@
2010-01-08plug a file descriptor leak in HASHFileChunk().Owain Ainsworth
From Igor Zinovik; thanks! ok millert@
2010-01-04Stop installing many of the incredibly dated and un-authoritative share/docTheo de Raadt
files. If any information found in these documents is worthwhile and you miss it, please make the time to work it into the manual pages (which people actually do read). ok guenther
2010-01-03Make SO_RCVTIMEO and SO_SNDTIMEO work with pthreads. Fixes at least some ofFederico G. Schwindt
the issues seen with www/varnish. With input and help from guenther@ and kurt@. guenther@ ok
2010-01-03Neither .Pp nor unqualified text are allowed at the top level of .Bl;Ingo Schwarze
instead, .It is required. Thus, move .Pp and text before the .Bl, and remove the .Pp altogether where it is not needed. Syntax errors found by mandoc(1), also required to fix the mandoc build; feedback and ok jmc@, and sobrado@ also supports the direction.
2010-01-03.Bl always requires .It, even in .Bl -column;Ingo Schwarze
syntax errors found by mandoc(1), also required to fix the mandoc build; feedback and ok jmc@ and sobrado@
2010-01-03blank lines not allowed outside literal context;Ingo Schwarze
syntax errors found by mandoc(1), also required to fix the mandoc build; ok jmc@
2009-12-31new ipsca root.David Gwynne
2009-12-31ipsca has expiredDavid Gwynne
2009-12-30Document ESPIPE and make EFAULT cover all functions.Federico G. Schwindt
jmc@ deraadt@ ok
2009-12-30explain what sio_close() drains play buffers as if sio_close() wasAlexandre Ratchov
called. Since sio_onmove() callback doesn't return negative deltas anymore, slightly simplify related paragraphs. siggested by espie@, ok jakemsr@
2009-12-29move this file to Attic; the swapon(2) system call cannot be accessedIgor Sobrado
from userland since April 2003 and, of course, the manual page is not built either. see miod@'s change in r1.66 of src/lib/libc/sys/Makefile.inc. i would like to acknowledge the excellent advice from jmc@ and fgsch@ with relation to this change. ok miod@
2009-12-29add missing paragraph break (.Pp) macro.Igor Sobrado
2009-12-29replace a few remaining UNIX terms with .Ux macros; this diffIgor Sobrado
completes the changes from Oct 22.
2009-12-27Security fix for CVE-2009-3560, which could allow attackers to causeJasper Lievisse Adriaanse
a DoS using a specially crafted XML document with malformed UTF-8 sequences. Patch taken from upstream CVS.
2009-12-19Implement proper error handling for getgrent(3), getgrnam(3) and getgrgid(3).Ingo Schwarze
1) Distinguish normal end of data (like eof, YPERR_NOMORE, YPERR_KEY) from error conditions. 2) Save errno(2) and restore it in case of success, as suggested by deraadt@ and beck@. While this code is touched, * move the common code for the yp_first and yp_next calls after the respective if/else-block; note that free(data) is not needed in case of failure and that __ypcurrent = NULL does no harm after failing yp_first. * return 0, not NULL: the return value of grscan is int, not a pointer. This is the last part of the work done on getgrent.c during c2k9, heavily relying on the other improvements done at that time. This has been rotting in my tree far too long. "get it in" deraadt@; also lightly tested by simon@ some time ago
2009-12-16save calls to arc4random() by using a nibble at a time; not becauseOtto Moerbeek
arc4random() is slow, but it induces getpid() calls; also saves a bit on stirring efforts
2009-12-16Update the list of async-signal-safe functionsPhilip Guenthe
Document that snprintf/vsnprintf/syslog_r() aren't async-signal-safe for floating-point Provide cursory documentation of SIGTHR Eliminate the NOTE section of the sigaction(2) manpage by merging the good bits into the STANDARDS section ok deraadt@
2009-12-15No point in refreshing the pid from inside arc4_stir() when thatPhilip Guenthe
doesn't test it, so factor out the two places that test it into a routine and do the refreshing there. With this, arch4random_buf() doesn't trigger superfluous calls to getpid() when filling large buffers. ok deraadt@, "looks nicer indeed" otto@
2009-12-14Keep all bits of __svc_fdset up to date, not just those beyond FD_SETSIZE.Ingo Schwarze
Bug found while auditing the same complaint by parfait, see the previous commit; still not shutting parfait up. "wow, that's nasty" deraadt@
2009-12-14sleep(3) is supposed to return zero when it sleeps the entire amountPhilip Guenthe
ok deraadt@
2009-12-11__svc_fdsetsize is counted in bits, not in array elementsIngo Schwarze
When exceeding fd 1024, this bug cleared flag bits for all file descriptors except those <= 64. Found while auditing a (false positive) complaint by parfait. This bugfix does not shut parfait up, though. OK millert@ deraadt@
2009-12-11Fix two memory leaks, one found by parfait, one by myself.Jacek Masiulaniec
ok deraadt@
2009-12-11clean up the realloc code to make a parfait false positive go away.Theo de Raadt
parfait still does not completely understand how realloc() behaves (or %, ?:, >>, or << and its terminal function tracking remains weak)
2009-12-11plug a memory leak; found by parfait, ok djmTheo de Raadt
2009-12-11More changes to avoid truncating 64 bit pointers to 32 bits and sign-extendingMiod Vallat
them; allows userland with stack beyond 2GB to run.
2009-12-10getcwd() is posix, not ansi; from Thomas PfaffJason McIntyre
ok millert
2009-12-10Make sure to use 64 bit instructions in the assembly statements (addi -> daddi)Miod Vallat
in the prologue; this gives a chance for binaries loaded with their stack over 2GB virtual, to run. Who's your daddi now?
2009-12-07Get page size information by reading the kernel image' struct uvmexp, insteadMiod Vallat
of the value of PAGE_SIZE found in the standard headers when compiling.
2009-12-07Make userland malloc use __LDPGSZ granularity on mips, regardless of theMiod Vallat
actual kernel page size.
2009-12-06Make internal file descriptor handling async-signal safe by eliminatingKurt Miller
the use of spinlocks and malloc. All needed memory is allocated upfront and _thread_kern_sig_defer/undefer() is now used to protect critical sections. okay guenther@
2009-12-05missing word;Jason McIntyre
from trhodes@freebsd, r200095;
2009-12-02we don't expose overruns/underruns as negative positions anymore,Alexandre Ratchov
don't call the sio_onmove() call-back with negative argument.
2009-11-28This might not be necessary, but Just In Case: since the underlyingPhilip Guenthe
syscall ABI has changed and everything is going to need to be relinked anyway, bump the rthread major
2009-11-27wrap Nd in quotes, since it has >9 args;Jason McIntyre
2009-11-27Correct description of physically vs logically; spotted by NickOtto Moerbeek
Guenther; ok jmc
2009-11-27Switch the chunk_info lists to doubly-linked lists and use the queueOtto Moerbeek
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@
2009-11-27Add setrdomain() and getrdomain() system calls. Committing now toPhilip Guenthe
catch the libc major bump per request from deraadt@ Diff by reyk. ok guenther@