summaryrefslogtreecommitdiffstats
path: root/lib/libpthread/uthread/uthread_fd.c (follow)
Commit message (Collapse)AuthorAgeFilesLines
* fix bug that would leave an FD locked if dup'd, then closed.marc2003-02-141-5/+23
| | | | Also, for safety lock the _thread_fd_table when removing entries.
* AARRGGH! 2nd try, handle the case where from_fd == to_fd in _thread_fd_table_dupmarc2003-02-051-2/+2
|
* handle the case where from_fd == to_fd in _thread_fd_table_dupmarc2003-02-051-15/+18
|
* thread fd handling, part 2. Don't mung file flags until forcedmarc2003-02-051-11/+15
| | | | | | | | to notice that the file exists. This fixes a problem where an application may think a file was in non-block mode because the threads kernel played with the flags. Also fix a stupid error introduced in the last commit -- the threaded version of dup and dup2 were foobared. Bad marc.
* Part 1 of thread fd handling fixes. In the new scheme fd_table_entriesmarc2003-02-041-21/+127
| | | | | | | | | | | | | | | | | for dup-ed fds are shared to ensure proper flag handling. A refcnt was added to control when entries should be freed. Specific changes: close: don't free entry unless refcnt is zero dup: rewrite to use new function _thread_fd_table_dup dup2: rewrite to use new function _thread_fd_table_dup fcntl: use _thread_fd_table_dup uthread_fd: initialize thread fd table, searching for dup-ed fds. Add function to share _thread_fd_table entries when an fd is dup-ed. uthread_init: make it readable. Call fd init functions. All current regression tests plus the mysql torture test pass. The new stdfiles regression test fails (I/O redirection problem). Part 2 is intended to fix that problem
* return (func(...)) not needed when the current function and funcmarc2003-01-191-3/+2
| | | | | | are both void. The select call is a cancellation point per IEEE Std 1003.1-2001. This should fix a problem espie@ found in kde.
* get rid of compiler warningsmarc2002-11-121-2/+1
|
* thread safe libc -- 2nd try. OK miod@, millert@marc2002-11-051-30/+11
| | | | Thanks to miod@ for m68k and vax fixes
* back out previous patch.. there are still some vax/m68k issuesmarc2002-11-031-11/+30
|
* libc changes for thread safety. Tested on:marc2002-11-031-30/+11
| | | | | | | alpha (millert@), i386 (marc@), m68k (millert@ and miod@), powerpc (drahn@ and dhartmei@), sparc (millert@ and marc@), sparc64 (marc@), and vax (millert@ and miod@). Thanks to millert@, miod@, and mickey@ for fixes along the way.
* removes duplicate functions and factor out common code so the needed (butmarc2002-10-301-463/+222
| | | | | | | | missing) _thread_fd_unlock_owned function can be added with minimal pain. The incorrect special handling of the stdio fds was also removed. Tested with the libc_r regression tests and the mysql regression tests. No complaints from any developers
* put changes back, this time ALL the files.fgsch2001-09-041-3/+3
|
* Back out fgsch@'s tree breaking commits.todd2001-08-301-3/+3
| | | | Test next time, ok?
* fix some const warnings.fgsch2001-08-301-3/+3
| | | | more sync with freebsd.
* Start syncing with FreeBSD:fgsch2001-08-211-25/+29
| | | | | | | | | | o Implement _get_curthread() and _set_curthread(). Use it where possible. o Add missing _thread_[enter|leave]_cancellation_point(). o Add a couple of not yet used vars to pthread_private.h. o Remove return's from void functions. This is by no means complete, but instead of doing a big commit, i'll split it in small ones, minimizing diffs.
* sync with FreeBSDd1999-11-251-23/+63
|
* sync with FreeBSDd1999-05-261-3/+3
|
* initialise locks properlyd1999-01-101-2/+2
|
* preserve FreeBSD identsd1998-12-231-2/+2
|
* sync with FreeBSD (rwlock, gc thread, man pages)d1998-11-091-3/+6
| | | | | | | add (broken) mips md stuff fix some const warnings add sigaltstack() stub another hash at getting shlib auto-init to work (mips/elf and i386/a.out)
* experimental threaded libc - kernel onlyd1998-08-271-0/+719