summaryrefslogtreecommitdiffstats
path: root/unix/tclUnixChan.c
Commit message (Collapse)AuthorAgeFilesLines
* * generic/tclEvent.c (TclInExit, TclInThreadExit):mdejong2002-11-071-2/+2
| | | | | | | | | | | | | | | Split out functionality of TclInExit to make it clear which one should be called in each situation. * generic/tclInt.decls: Declare TclInThreadExit. * generic/tclIntDecls.h: Regen. * generic/tclStubInit.c: Regen. * mac/tclMacChan.c (StdIOClose): * unix/tclUnixChan.c (FileCloseProc): * win/tclWinChan.c (FileCloseProc): * win/tclWinConsole.c (ConsoleCloseProc): * win/tclWinPipe.c (TclpCloseFile): * win/tclWinSerial.c (SerialCloseProc): Invoke the new TclInThreadExit method instead of TclInExit.
* * unix/tclUnixChan.c (Tcl_MakeTcpClientChannel): make sure to inithobbs2002-09-031-1/+2
| | | | flags field of TcpState ptr to 0.
* * unix/tcl.m4 (SC_SERIAL_PORT): Fixed detection for cases whenrmax2002-07-291-5/+5
| | | | | | | | | | | | | configure's stdin is not a tty. * unix/tclUnixPort.h: * generic/tclIOSock.c: Changed size_t to socklen_t in socket-related function calls. * unix/configure.in: Added test and fallback definition for socklen_t. * unix/configure: generated.
* fs cleanupvincentdarley2002-07-081-21/+4
|
* Changed all the Tcl_Platform* symbols to TclOS*; they weren't public so theirdkf2002-06-281-12/+21
| | | | names were really badly chosen. Also prevented a double-#def.
* TIP#91 implementation; makes old style channels binary compatible withdkf2002-05-241-11/+71
| | | | new TIP#72-enabled Tcl. See http://purl.org/tcl/tip/91 for details.
* More tidying up; tclUnixChan.c now builds with GCC without warnings.dkf2002-05-141-480/+456
|
* Stop Solaris from generating a warning; the second argument to ioctl has beendkf2002-05-131-2/+6
| | | | observed to be either signed (Solaris) or unsigned (Linux)...
* * unix/tclUnixChan.c: initial remedy for [Bug #525783] flushhobbs2002-03-051-4/+23
| | | | | | problem introduced by TIP #35. This may not satisfy true serial channels, but it restores the correct flushing of std* channels on exit.
* * unix/tclUnixChan.c (TclpOpenFileChannel): Added code to regonizeandreas_kupries2002-02-271-2/+8
| | | | | | | | | | "/dev/tty" (by name) and to not handle it as tty / serial line. This is the controlling terminal and is special. Setting it into raw mode as is done for other tty's is a bad idea. This is a hackish fix for expect SGF Bug #520624. The fix has limitation: Tcl_MakeFileChannel handles tty's specially too, but is unable to recognize /dev/tty as it only gets a file descriptor, and no name for it.
* * unix/tclUnixChan.c: added Unix implementation of TIP #35, serialhobbs2002-02-261-16/+385
| | | | port support. [Patch #438509] (schroedter)
* TIP#72 implementation. See ChangeLog for details.dkf2002-02-151-15/+16
| | | | | This version builds clean on Solaris/SPARC, with GCC and CC, both with and without threads and both in 32-bit and 64-bit mode.
* * unix/tclUnixChan.c (FileOutputProc): Fixed [bug 465765] reportedandreas_kupries2002-02-041-1/+11
| | | | | | | | by Dale Talcott <daletalcott@users.sourceforge.net>. Avoid to write nothing into a file as STREAM based implementations will consider this a EOF (if the file is a pipe). Not done in the generic layer as this type of writing is actually useful to check the state of a socket.
* * Updated socket interfaces according to TIP 27. Updated callers.dgp2002-01-231-11/+11
|
* * More TIP 27 updates in tclIOUtil.c and tclIndexObj.c that weredgp2002-01-171-2/+2
| | | | | | | overlooked before. Updated callers. ***POTENTIAL INCOMPATIBILITY*** Includes a source incompatibility in the tablePtr arguments of the Tcl_GetIndexFromObj* routines.
* * Updated APIs in generic/tclIOUtil.c and generic/tclPosixStr.cdgp2002-01-151-2/+2
| | | | according to the guidelines of TIP 27. Updated callers. [Patch 499196]
* * Updated APIs in the file generic/tclIO.c according to the guidelinesdgp2002-01-151-14/+14
| | | | | | | | | | | of TIP 27. Several minor documentation corrections as well. * Updated channel driver interface according to the guidelines of TIP 27. See also [Bug 500348]. * Moved Tcl_EolTranslation enum declaration from generic/tcl.h to generic/tclInt.h (renamed to TclEolTranslation). It is not used anywhere in Tcl's public interface.
* added TIP#73 patch #483500 from Kevin Kenny.hobbs2001-11-211-3/+3
| | | | This deprecates TclpGetTime in favor of new Tcl_GetTime.
* Fix for bug 471374; Tcl only resets serial ports on exit now if it hasdkf2001-10-251-15/+29
| | | | updated their settings first.
* filesystemvincentdarley2001-08-301-11/+8
|
* Unix channels now have the right type associated with them [bug #219137]dkf2001-06-181-29/+58
| | | | A couple of nasty faults/assumptions in unixInit.test are fixed too.
* * unix/tclUnixChan.c: updated channel types to stricthobbs2000-10-281-31/+43
| | | | | TCL_CHANNEL_VERSION_2 style to avoid compiler warnings. They work either way, but this avoids compiler warnings (that worries people).
* 2000-05-02 Andreas Kupries <a.kupries@westend.com>kupries2000-05-021-4/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Overall changes: (1) Implementation of joinable threads for all platforms. (2) Additional API's for channels. Required to allow the thread extension to move channels between threads. * generic/tcl.decls (lines 1360f): Added Tcl_JoinThread, Tcl_IsChannelShared, Tcl_IsChannelRegistered, Tcl_CutChannel, Tcl_SpliceChannel, Tcl_IsChannelExisting and Tcl_ClearChannelHandlers (slots 394 to 400). * generic/tclIO.c: Implemented Tcl_IsChannelRegistered, Tcl_IsChannelShared, Tcl_CutChannel, Tcl_SpliceChannel, Tcl_IsChannelExisting and Tcl_ClearChannelHandlers. Tcl_CutChannel uses code from CloseChannel. Replaced this code by a call to Tcl_CutChannel. Replaced several code fragments adding channels to the channel list with calls to Tcl_SpliceChannel. Removed now unused variables from CloseChannel and Tcl_UnstackChannel. Tcl_ClearChannelHandlers uses code from Tcl_Close. Replaced this code by a call to Tcl_ClearChannelHandlers. Removed now unused variables from Tcl_Close. Added the subcommands 'cut', 'forgetch', 'splice' and 'isshared' to the test code (TclTestChannelCmd). * unix/tclUnixThread.c: Implemented Tcl_JoinThread using the pthread-functionality. * win/tclWinThrd.c: Fixed several small typos in comments. Implemented Tcl_JoinThread using a platform independent emulation layer (see generic/tclThreadJoin.c below). Added 'joinLock' to serialize Tcl_CreateThread and TclpExitThread to prevent a race for joinable threads. * mac/tclMacThrd.c: Implemented Tcl_JoinThread using a platform independent emulation layer (see generic/tclThreadJoin.c below). Due to the cooperative nature of threading on this platform the race mentioned above is not present. * generic/tclThreadJoin.c: New file. Contains a platform independent emulation layer helping in the implementation of joinable threads for the win and mac platforms. * generic/tclInt.h: Added declarations for TclJoinThread, TclRememberJoinableThread and TclSignalExitThread. These procedures define the API of the emulation layer for joinable threads (see generic/tclThreadJoin.c above). * win/Makefile.in: * win/makefile.vc: Added generic/tclTheadJoin.o to the rules. * mac/: I don't know to which file generic/tclTheadJoin.o has to be added to so that it compiles. Sorry. * unix/tclUnixChan.c: #ifdef'd the thread-local list of file channels as it prevents us from transfering channels. To restore this we may need an extended interface to drivers in the future. Target: 9.0. Found while testing the new transfer of channels. The information in this list for a channel was left behind and then crashed the system during finalization. * generic/tclThreadTest.c: Added -joinable flag to 'testthread create'. Added subcommand 'testthread join'. * doc/CrtChannel.3: Added documentation for Tcl_IsChannelRegistered, Tcl_IsChannelShared, Tcl_CutChannel, Tcl_SpliceChannel, Tcl_IsChannelExisting and Tcl_ClearChannelHandlers. * doc/Thread.3: Added documentation for Tcl_JoinThread. * tests/thread.test: Added tests for joining of threads.
* have to allow for strchr being a macro in TtyParseProchobbs2000-04-191-5/+6
|
* * README:hobbs2000-04-191-2/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * generic/tcl.h: * tools/tcl.wse.in: * unix/configure.in: * unix/tcl.spec: * win/configure.in: * win/README.binary: bumped version to 8.3.1 * win/tcl.hpj.in: updated copyright date * generic/tclEnv.c: environment support for Mac OS/X * unix/tclUnixPort.h: environment support for Mac OS/X * unix/tclLoadDyld.c: new file for Mac OS/X dl functions * unix/Makefile.in: added install-strip target; bindir, libdir, mandir, includedir vars; tclLoadDyld.c target [Bug: 2527] * unix/tclUnixChan.c (CreateSocket): force a socket back into blocking mode (default state) after a -async connect succeeds. [Bug: 4388] * generic/tclEvent.c (TclInitSubsystems): Moved tclLibraryPath to thread-local storage to prevent thread-related race condition. [Bug: 5033] * unix/tclAppInit.c (main): removed #ifdef TCL_TEST that sets the library path as it was unnecessary and conflicts with move of tclLibraryPath to thread-local storage.
* * unix/tclUnixChan.c (TtyParseMode): Only allow setting mark/spacehobbs2000-04-151-3/+18
| | | | parity on platforms that support it [Bug: 5089]
* * unix/tclUnixChan.c: Added (off_t) type casts in lseek() callericm2000-03-271-2/+2
| | | | | | | | [Bug: 4409]. * unix/tclLoadAout.c: * unix/tclUnixPipe.c: Added (off_t) type casts in lseek() calls [Bug: 4410].
* * unix/tcl.m4: modified EXTRA_CFLAGS to add -DHAVE_TZSET forhobbs2000-01-261-4/+4
| | | | | | | | OSF1-V* and ULTRIX-4.* when not using gcc. Also added higher min stack size for OSF1-V* when building with threads. [Bug: 4063] * unix/tclUnixChan.c (CreateSocketAddress): changed comparison with -1 to 0xFFFFFFFF, to ensure 32 bit comparison even on 64 bit systems. [Bug: 3878]
* * unix/tclUnixPort.h: moved include of <utime.h> lower since somehobbs2000-01-241-2/+6
| | | | | | | | systems (UTS) require sys/types.h to be included first [Bug: 4031] * unix/tclUnixChan.c (CreateSocketAddress): changed comparison with -1 to 0xFFFFFFFFFFFFFFF, which is the pedantic way to say -1 for both 32 bit and 64 bit systems. [Bug: 3878]
* * unix/tclUnixPort.h: added utime.h to includeshobbs1999-10-291-3/+3
| | | | * unix/aclocal.m4: made it just include tcl.m4
* merged tcl 8.1 branch back into the main trunkstanton1999-04-161-228/+330
|
* * unix/tclUnixChan.c:stanton1999-02-031-1/+18
| | | | | | | * win/tclWinSock.c: * doc/socket.n: Applied Gordon Chaffee's patch to handle failures during asynchronous socket connection operations. This adds a new "-error" fconfgure option to socket channels. [Bug: 893]
* Updated the version to 8.0.5.rjohnson1999-01-041-1/+4
|
* Replaced SCCS strings, fixed binary filescore_8_0_3stanton1998-09-141-1/+1
|
* Nuked EINTR wrapperswelch1998-08-061-100/+0
|
* *** empty log message ***welch1998-08-041-1/+1
|
* Fixed EINTR bugsurles1998-08-031-0/+100
|
* changed so server sockets can't be trashed by fileeventstanton1998-06-091-6/+14
|
* Renamed function 'Tcl_OpenFileChannel' to 'TclpOpenFileChannel'.suresh1998-06-031-3/+3
|
* Initial revisionrjohnson1998-03-261-0/+2565