summaryrefslogtreecommitdiff
path: root/lib
AgeCommit message (Collapse)Author
2012-03-01Update to tzcode2012a from munnari.oz.auTodd C. Miller
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-28Our default mutex type is PTHREAD_MUTEX_ERRORCHECK, for which tryingPhilip Guenthe
to unlock an uninitialized mutex is required to return EPERM, so add the necessary checks. For recursive mutexes, return an error from pthread_mutex_lock() if the count would overflow. problem observed in glib testing by aja@
2012-02-27fix __errno symbol nameMiod Vallat
2012-02-26Fix buglets.Miod Vallat
2012-02-26Fix several manpage titles, from Lawrence Teo.Christiano F. Haesbaert
ok dcoppa@ jmc@ schwarze@.
2012-02-26__cerror gets invoked with errno in v0, not a0.Miod Vallat
2012-02-26Fix label for threaded binaries to link.Miod Vallat
2012-02-25Apply a bit more consistency in the ordering of functions in eachPhilip Guenthe
group of functions. No objection from jmc@
2012-02-24Add pthread_condattr_{get,set}clock(), pthread_mutex_timedlock(),Philip Guenthe
and pthread_rwlock_{timed,try}{rd,wr}lock(). Requested by jmc@
2012-02-24jmc@ points out that the underlying manpage should be named after onePhilip Guenthe
of the functions, not a generic name that doesn't itself exist
2012-02-24now that pthread_mutex_trylock.3 has been folded into pthread_mutex_lock.3,Jason McIntyre
don;t list both pages in SEE ALSO;
2012-02-24Correct the spelling of "transferred" and "transferring"Philip Guenthe
from Tobias Ulmer (tobiasu at tmux.org); ok jmc@, krw@
2012-02-24sched_yield() is the standard name while pthread_yield() is thePhilip Guenthe
non-standard alias, so prefer the former
2012-02-24Document pthread_condattr_{init,destroy,setclock,getclock}Philip Guenthe
2012-02-24Merge pthread_mutex_trylock(3) into pthread_mutex_lock(3) and documentPhilip Guenthe
pthread_mutex_timedlock() in that same page ok fgsch@, brad@, as well as jmc@, who also fixed a bunch of nits
2012-02-23PTHREAD_MUTEX_NORMAL mutexes are supposed to self-deadlock, not abort.Philip Guenthe
That deadlock can be exited via a timeout for pthread_mutex_timedlock(). Unwind all the state when pthread_mutex_timedlock() times out
2012-02-23Add pthread_condattr_{get,set}clock(), requested by aja@Philip Guenthe
Add pthread_mutex_timedlock(), requested by dcoppa@
2012-02-21Make pthread_suspend_np() and pthread_resume_np() simply fail insteadPhilip Guenthe
of doing the Wrong Thing.
2012-02-19Fix return value documentation errors in usbhid(3).Stefan Sperling
hid_dispose_report_desc() returns void, it can't return NULL on failure. hid_get_report_desc() and hid_use_report_desc() return NULL on failure but this was not documented. ok jmc
2012-02-19Fix problems revealed by regress/lib/libpthread/stack/stack.cPhilip Guenthe
2012-02-19Use 'base' as an intermediate char* variable to avoid void* arithmeticPhilip Guenthe
2012-02-19Extend miod's fix CFLAGS fix to all gcc2 platforms (suggested by TobiasPhilip Guenthe
Ulmer). Only pull in bsd.lib.mk once to avoid linking objects twice
2012-02-19Use a form of designated initializer that works with gcc2Philip Guenthe
lint doesn't understand designated initializers, so hide them from it
2012-02-19Validate in pthread_attr_set{scope,sched{param,policy},inheritsched}()Philip Guenthe
the requested new value
2012-02-18Fix previous commit: _rthread_init() was static.Philip Guenthe
Improve consistency of error naming
2012-02-18Before using _thread_pagesize, make sure _rthread_init() has been calledPhilip Guenthe
2012-02-18id tag.Federico G. Schwindt
2012-02-18Fix the handling of the stackaddr, stacksize, and guardsize attributes:Philip Guenthe
don't try to merge values, round the sizes separately, and don't try to unmap application-supplied stacks. Copy from uthread the caching of default-sized stacks. Have pthread_attr_init() and pthread_create() get the default attributes from staticly allocated pthread_attr_t. Cache the pagesize in _rthread_init() and provide a macro for rounding to it based on suggestions from kettenis@ and tedu@, ok kettenis@
2012-02-18Missing cerror bits.Miod Vallat
2012-02-18Work around compiler confusion while building rthread.o on vax.Miod Vallat
2012-02-18Extend after recent msdos support.Antoine Jacoutot
input/ok krw@ thib@ jmc@
2012-02-18Initialize the scope, policy, and inherit members in pthread_attr_init()Philip Guenthe
so that their pthread_attr_get* don't return bogus values. issue noted and tested by aja@
2012-02-17Allow librthread to build on mips64.Miod Vallat
2012-02-16Set __isthreaded in pthread_create() instead of _rthread_init() such that itMark Kettenis
properly represents whether a process is multi-threaded or not. This fixes a bug where if a forked child would create a new thread we would not set __isthreaded. ok guenther@
2012-02-15Nothing important, just switching from pthreads to rthreadsPhilip Guenthe
2012-02-15Bump major to be current libpthread major +1, so we can switch over cleanly.Philip Guenthe
If we have to revert to user-space threads, we'll do another major bump of libpthread going back
2012-02-15Add pthread_rwlockattr_{get,set}pshared() andPhilip Guenthe
pthread_mutexattr_{get,set}kind_np() tweaked diff from brad
2012-02-08r1.27 changed libevent to fire a read event when kqueue returned EBADFNicholas Marriott
(and several other things, particularly EPIPE) on a file descriptor. This causes Google Chrome to die (probably due to a bug in Chrome but finding that is next to impossible at the moment). It's not really clear what libevent should when an invalid fd is added - the poll backend doesn't fire an event and select exits the event loop. Until this is settled, change kqueue to match poll and ignore EBADF, keeping the behaviour r1.27 fixed on EPIPE. Fix from robert@.
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@
2012-02-04If the internal consistency check fails, set errno so that it doesn'tPhilip Guenthe
just look like end-of-directory. ok krw@ otto@ miod@
2012-01-30Handle a wider range of kqueue error return values for an event,Nicholas Marriott
prevents libevent exiting the event loop when getting EPIPE. Problem first seen by drahn@ and more recently hit by gilles@, fix based on one by Nick Mathewson. ok gilles
2012-01-25@($*& Merging patches resulted in a line being duplicated instead ofPhilip Guenthe
moved. Unlocking a spinlock twice is bad, mmkay?
2012-01-22Credit Keith Sklower and 2BSD for the first implementation of read-writeIngo Schwarze
access; information found in the 2bsd directory of the CSRG archive CDs. feedback and ok jmc@
2012-01-20the glob stat limit is way too low. bump to 2048.Ted Unangst
while here, failed stats should count against the limit too. ok deraadt sthen stsp
2012-01-19symetryMarc Espie
ok jmc@, millert@
2012-01-18remove unused variableCharles Longeau
ok guenther@
2012-01-18Add missing header needed by iswspace()Charles Longeau
ok stsp@
2012-01-18Add support for C99 %ls, %lc, and %l[ format directives to scanf(3).Stefan Sperling
Based on code from FreeBSD. Tested by myself (full release/install cycle on i386 and sparc64) and ajacoutot. Man page help from jmc.
2012-01-17Remove assembly version of strlen from i386 and amd64, where it'sMike Belopuhov
up to 3 times slower than the C code most of the time. This was brought up by DragonflyBSD guys initially. ok deraadt, guenther. miod will not miss it.