aboutsummaryrefslogtreecommitdiff
path: root/lib/libc/db/hash/hash_page.c
Commit message (Collapse)AuthorAgeFilesLines
* Switch libc from using _sig{procmask,action,suspend} symbols, whichKonstantin Belousov2015-08-291-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | are aliases for the syscall stubs and are plt-interposed, to the libc-private aliases of internally interposed sigprocmask() etc. Since e.g. _sigaction is not interposed by libthr, calling signal() removes thr_sighandler() from the handler slot etc. The result was breaking signal semantic and rtld locking. The added __libc_sigprocmask and other symbols are hidden, they are not exported and cannot be called through PLT. The setjmp/longjmp functions for x86 were changed to use direct calls, and since PIC_PROLOGUE only needed for functional PLT indirection on i386, it is removed as well. The PowerPC bug of calling the syscall directly in the setjmp/longjmp implementation is kept as is. Reported by: Pete French <petefrench@ingresso.co.uk> Tested by: Michiel Boland <boland37@xs4all.nl> Reviewed by: jilles (previous version) Sponsored by: The FreeBSD Foundation MFC after: 1 week Notes: svn path=/head/; revision=287292
* db: Use O_CLOEXEC instead of separate fcntl() call.Jilles Tjoelker2013-08-131-3/+1
| | | | Notes: svn path=/head/; revision=254289
* Add some casts to silence compiler warning about signedness.Xin LI2009-03-281-1/+1
| | | | Notes: svn path=/head/; revision=190500
* Fix a crash when iterating over a hash and removing its elements.Xin LI2009-03-281-0/+8
| | | | | | | Obtained from: OpenBSD Notes: svn path=/head/; revision=190491
* Only squeeze a short key/value pair onto a page with other complete key/valueXin LI2009-03-281-3/+9
| | | | | | | | | pairs, not onto a page containing the end of a big pair. Obtained from: NetBSD via OpenBSD Notes: svn path=/head/; revision=190490
* Diff reduce against OpenBSD, no functional change.Xin LI2009-03-281-10/+5
| | | | Notes: svn path=/head/; revision=190489
* Return meaningful errno in overflow case; print error message to stderrXin LI2009-03-281-1/+7
| | | | | | | | | in one more case. Obtained from: NetBSD via OpenBSD Notes: svn path=/head/; revision=190487
* Use pread(2) and pwrite(2) instead of lseek(2) + read(2) / write(2).Xin LI2009-03-281-4/+2
| | | | | | | Obtained from: NetBSD via OpenBSD Notes: svn path=/head/; revision=190486
* db/btree/bt_open.c: check return value of snprintf() and return valueXin LI2009-03-281-4/+15
| | | | | | | | | | | | if the result is truncated. db/hash/hash_page.c: use the same way to create temporary file as bt_open.c; check snprintf() return value. Obtained from: OpenBSD Notes: svn path=/head/; revision=190485
* Diff reduction against OpenBSD: ANSI'fy prototypes.Xin LI2009-03-021-73/+41
| | | | | | | | | | | (This is part of a larger changeset which is intended to reduce diff only, thus some prototypes were left intact since they will be changed in the future). Verified with: md5(1) Notes: svn path=/head/; revision=189291
* Per Regents of the University of Calfornia letter, remove advertisingWarner Losh2007-01-091-4/+0
| | | | | | | | | clause. # If I've done so improperly on a file, please let me know. Notes: svn path=/head/; revision=165903
* Remove __P() usage.David E. O'Brien2002-03-211-7/+7
| | | | Notes: svn path=/head/; revision=92905
* Remove 'register' keyword.David E. O'Brien2002-03-211-29/+29
| | | | Notes: svn path=/head/; revision=92889
* Remove _THREAD_SAFE and make libc thread-safe by default byDaniel Eischen2001-01-241-2/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | adding (weak definitions to) stubs for some of the pthread functions. If the threads library is linked in, the real pthread functions will pulled in. Use the following convention for system calls wrapped by the threads library: __sys_foo - actual system call _foo - weak definition to __sys_foo foo - weak definition to __sys_foo Change all libc uses of system calls wrapped by the threads library from foo to _foo. In order to define the prototypes for _foo(), we introduce namespace.h and un-namespace.h (suggested by bde). All files that need to reference these system calls, should include namespace.h before any standard includes, then include un-namespace.h after the standard includes and before any local includes. <db.h> is an exception and shouldn't be included in between namespace.h and un-namespace.h namespace.h will define foo to _foo, and un-namespace.h will undefine foo. Try to eliminate some of the recursive calls to MT-safe functions in libc/stdio in preparation for adding a mutex to FILE. We have recursive mutexes, but would like to avoid using them if possible. Remove uneeded includes of <errno.h> from a few files. Add $FreeBSD$ to a few files in order to pass commitprep. Approved by: -arch Notes: svn path=/head/; revision=71579
* Simplify sytem call renaming. Instead of _foo() <-- _libc_foo <-- foo(),Jason Evans2000-01-271-8/+6
| | | | | | | | | | | | | | | | | | | | just use _foo() <-- foo(). In the case of a libpthread that doesn't do call conversion (such as linuxthreads and our upcoming libpthread), this is adequate. In the case of libc_r, we still need three names, which are now _thread_sys_foo() <-- _foo() <-- foo(). Convert all internal libc usage of: aio_suspend(), close(), fsync(), msync(), nanosleep(), open(), fcntl(), read(), and write() to _foo() instead of foo(). Remove all internal libc usage of: creat(), pause(), sleep(), system(), tcdrain(), wait(), and waitpid(). Make thread cancellation fully POSIX-compliant. Suggested by: deischen Notes: svn path=/head/; revision=56698
* Add three-tier symbol naming in support of POSIX thread cancellationJason Evans2000-01-121-6/+10
| | | | | | | | | points. For library functions, the pattern is __sleep() <-- _libc_sleep() <-- sleep(). The arrows represent weak aliases. For system calls, the pattern is _read() <-- _libc_read() <-- read(). Notes: svn path=/head/; revision=55837
* Fix conflicts and merge into mainlinePaul Traina1996-02-271-85/+85
| | | | Notes: svn path=/head/; revision=14287
* Remove trailing whitespace.Rodney W. Grimes1995-05-301-1/+1
| | | | Notes: svn path=/head/; revision=8870
* BSD 4.4 Lite Lib SourcesRodney W. Grimes1994-05-271-0/+944
Notes: svn path=/cvs2svn/branches/unlabeled-1.1.1/; revision=1573