summaryrefslogtreecommitdiffstats
path: root/lib (follow)
Commit message (Collapse)AuthorAgeFilesLines
* getpwnam_r() and getpwuid_r() reopen the passwd even when called withbenno2013-11-151-7/+3
| | | | | | | setpassent(stayopen). Bug found and fixed by Erik Lax <erik-AT-halon-DOT-se> ok millert@ guenther@
* Prefix by '_' symbols that are not part of the API.ratchov2013-11-1313-143/+142
| | | | ok deraadt, guenther
* repair prototypesderaadt2013-11-135-70/+61
| | | | reviewed by chris
* fix_options() is not used by anything; remove API, crank majorderaadt2013-11-133-104/+3
| | | | ok sthen
* document that ibuf_write() and msgbuf_write() can now return EAGAINbenno2013-11-131-3/+9
| | | | from and with deraadt@
* original bug diagnosed by sthen: automatic retry in msgbuf_write onbenno2013-11-131-3/+3
| | | | | | | | | | | EAGAIN causes spinning. fix from claudio: "Let msgbuf_write return -1 with errno EAGAIN. The users then must check if this was the case and readd the event or poll again. The current handling in the imsg code is wrong for sure." ok gilles
* Remove redundant extern "C" {...}. ok deraadt@jca2013-11-131-8/+1
|
* Document the negative errno quirk used by callbacks in struct fuse_operations.stsp2013-11-131-1/+6
| | | | ok syl
* use sysctl vm.psstrings to calculate stack bounds, rather than USRSTACK.deraadt2013-11-131-18/+31
| | | | long discussions with guenther, kurt, kettenis etc etc etc
* correct types for arguments to the x509 functionsderaadt2013-11-131-5/+6
| | | | ok markus
* oops should not be staticderaadt2013-11-131-2/+2
|
* bring in protoderaadt2013-11-131-1/+2
|
* bring in math.h to provide prototypesderaadt2013-11-133-3/+6
|
* Trick the compiler that volatile temporary is used while raisingmartynas2013-11-123-0/+12
| | | | the underflow.
* remove dead fileseric2013-11-1211-7785/+0
| | | | ok deraadt@
* Declare __p1evll and __polevll protos in math_private.h instead ofmartynas2013-11-1210-27/+30
| | | | redeclaring each time in ld{80,128}. Pointed out by theo.
* put the _readdir_unlocked() prototype in an obvious placederaadt2013-11-122-4/+4
|
* Add parentheses around comparison in operand of ^. Pointed out by theo.martynas2013-11-122-10/+10
|
* Add explicit braces to avoid ambiguous else. Pointed out by theo.martynas2013-11-1210-18/+27
|
* Apply format __attribute__ to _kvm_err() and fix the errors that it detects.guenther2013-11-123-43/+57
| | | | | | | Treat failure to KREAD teh pcredd or ucreds to be errors insteading of continuing with bogus data. ok deraadt@ millert@
* ANSI prototypesderaadt2013-11-121-3/+3
|
* a __fputwc_unlock() prototype was available in fvwrite.h, so use thatderaadt2013-11-124-8/+7
|
* both files contain a function which should only be static.deraadt2013-11-122-4/+4
| | | | not cranking libc over this (unless an issue is found in ports)
* permute15() should be static. Not cranking libc now, because it isderaadt2013-11-121-2/+2
| | | | not urgent.
* insert the proper arguments into a prototypederaadt2013-11-121-2/+2
|
* avoid arithetic on void *deraadt2013-11-121-4/+4
| | | | ok guenther otto
* internalize some functions so that they do not need prototypesderaadt2013-11-121-4/+4
| | | | ok ratchov
* ANSI prototypederaadt2013-11-121-2/+2
|
* pull in missing includes (math.h, unistd.h, stdlib.h) needed forderaadt2013-11-128-8/+17
| | | | prototypes
* pull in stdlib.h as requiredderaadt2013-11-121-1/+2
|
* add proto for amd64 case; unify otherwisederaadt2013-11-122-3/+5
|
* ttyslot() needs <stdlib.h>deraadt2013-11-121-2/+3
| | | | ok guenther
* a missing prototypesderaadt2013-11-121-1/+6
| | | | and don't act like an unknown vnode type is "ok"
* In fuse_loop(), use ssize_t to store return values from read(2) and write(2).stsp2013-11-111-6/+6
| | | | ok syl@
* The kernel and ld.so have passed 0 in r0 for use as the cleanupguenther2013-11-101-11/+6
| | | | | | | | | | callback for about a year, so it's safe to make __start() pass that as the cleanup argument to ___start(), and have *that* conditionally pass it to atexit(). Eliminate the no-longer-used obj and ps_strings arguments to position things correctly, simplifying the ASM wrapper slightly. ok kettenis@ miod@; testing patrick@
* The kernel and ld.so have passed 0 in r7 for use as the cleanupguenther2013-11-101-19/+5
| | | | | | | | | callback for about a year, so it's safe to make __start() treat that as the cleanup argument and conditionally pass it to atexit(). Eliminate the no-longer-used obj and ps_strings arguments to position things correctly, which lets us eliminate the ASM wrapper completely. ok kettenis@ miod@
* The kernel and ld.so pass 0 in %rdx for use as the cleanup callbackguenther2013-11-101-11/+6
| | | | | | | | for about a year, so it's safe to add the test and atexit() call. While here, drop the no-longer-used obj and ps_strings and the asm to set those up, switch from sys/param.h to limits.h, and ANSIfy. ok kettenis@
* Simplify fuse_unmount(). No functional change.stsp2013-11-091-7/+3
| | | | ok jung@
* Properly check realpath() return value during argv processing in libfuse.stsp2013-11-091-3/+8
| | | | tweak & ok syl@
* add fuse_invalidate() and fuse_setup() functions.syl2013-11-072-11/+33
| | | | ok tedu@
* Nowadays, seekdir(3) doesn't call _readdir_unlocked().schwarze2013-11-062-14/+7
| | | | | | Consequently, the "skipdeleted" argument is always == 1. Remove it, effectively reverting readdir.c rev. 1.14. ok millert@ guenther@
* Search the userland buffer of dirent structures before falling back toschwarze2013-11-062-26/+46
| | | | | | | getdents(2). No functional change, but considerable speedup in many cases, see http://marc.info/?l=openbsd-tech&m=138369623117934 for some approximate numbers. ok guenther@, "good diagnosis" deraadt@
* Handle fuse client private data. Needed by encfs.syl2013-11-063-3/+6
| | | | | | Bump shlib_version. ok stsp@.
* Cleanup, no functional change:schwarze2013-11-054-41/+12
| | | | | | | | 1. avoid code duplication in rewinddir() by calling seekdir() directly 2. move __seekdir() into seekdir() and _telldir_unlocked() into telldir() Both functions were called from nowhere else. 3. remove some unused #include directives and one unused function prototype ok otto@ millert@
* Make sure seekdir(3) works even when dirp->dd_buf still contains someschwarze2013-11-051-1/+2
| | | | | | | | | | | | | pending entries: At the time of the lseek(2), also invalidate the buffer in order to force getdents(2) during the next readdir(3). Because this throws away buffered data that could still be used in some cases, this is not particularly efficient, but at least it works; i will suggest optimizations soon. Bug found when investigating perl-5.18.1/t/op/threads-dirh.t that was reported broken by Andrew Fresh <andrew at afresh1 dot com>. ok guenther@ deraadt@
* fuse_opt_insert_arg() can take empty string as argument.syl2013-11-041-2/+2
| | | | | unbreak ntfs-3g. ok pirofti@
* NaN -> \*(Namartynas2013-11-037-23/+23
| | | | | {infinity, inf} -> \*(If OK jmc@
* remove unnecessary spinlock that slowed down pthread_getspecific.tedu2013-11-021-4/+2
| | | | original report and fix provided by John Carr. ok guenther kettenis
* Oops, utime() is section 3, not 2guenther2013-11-021-2/+2
| | | | noted by jmc@
* Fix lie that predated NetBSD: the struct stat time padding affectedguenther2013-11-021-3/+3
| | | | | | utime() usage, not utimes() ok deraadt@