| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
| |
* generic/tclIO.c: moved channel test commands from tclIO.c to
tclTest.c.
* generic/tclIO.h: new file, split out from tclIO.c to allow test
commands to be moved to tclTest.c.
* generic/tclStubInit.c:
* generic/tclIntDecls.h:
* generic/tclInt.decls: removed TclTestChannel*Cmd from internal
stubs table and added TclChannelEventScriptInvoker to the internal
stubs table so it can be used from the test code.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* 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.
|
|
|
|
|
|
|
|
| |
* generic/tclIO.c (Tcl_UnstackChannel, line 1831): Forcing interest
mask to the correct value after an unstack and re-initialization
of the notifier via the watchProc. Without this the first
fileevent after an unstack will come through and be processed,
but no more. [Bug: ??].
|
|
|
|
| |
* generic/tclThreadTest.c: changed thread ids to longs [Bug: 3902]
|
|
|
|
|
|
|
|
|
|
|
|
| |
* unix/Makefile.in: fixed make gendate to swap const with CONST
so it uses the Tcl defined CONST type [Bug: 3521]
* generic/tclIO.c: removed panic that could occur in FlushChannel
when a "blocking" channel would receive EAGAIN, instead treating
it the same as non-blocking. [Bug: 3773]
* generic/tclUtil.c: fixed Tcl_ScanCountedElement to not step
beyond the end of the counted string [Bug: 3336]
|
|
|
|
| |
correctly handles resetting translation and encoding.
|
|
|
|
|
| |
* generic/tclIO.c: changed Tcl_GetChannelNames* to use K&R
style headers (style guide, also pleases HP cc)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* doc/OpenFileChnl.3:
* doc/file.n:
* tests/cmdAH.test:
* tclIO.c:
* tclCmdAH.c: added "file channels ?pattern?" tcl command, with
associated Tcl_GetChannelNames and Tcl_GetChannelNamesEx public
C APIs (added to tcl.decls as well), with docs and tests.
* generic/tclCompile.c: add TCL_TOKEN_VARIABLE to the part types
that cause differed compilation for exprs, to correct the expr
double-evaluation problem for vars. Added test cases.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* generic/tcl.decls:
* generic/tclDecls.h: Applied patch from Jim Ingham to change the
prototype of Tcl_ListObjGetElements to have the last argument have
a CONST so that you can feed it the objv that you get from the
standard TclObj command proc.
* generic/tclAlloc.c:
* generic/tclCmdIL.c:
* generic/tclIO.c:
* generic/tclThread.c:
* win/tclWinThrd.c:
* unix/tclUnixThrd.c: Fixed Brent's changes so that they work on
Windows (and he fixed the bug in the Unix thread implementation).
|
|
|
|
|
|
|
|
| |
can be linked against alternate thread packages.
2 Added Tcl_GetChannelNames to tclIO.c
3 Added TclVarTraceExists hook so "info exists" triggers read traces
exactly like it did in Tcl 7.6
4 Stubs table changes to reflect new internal and external APIs
|
|
|
|
| |
previous patch to our specs.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* win/tclWinPort.h: Block out include of sys/*.h in order to
build extensions with MetroWerks compiler for Win32. [Bug: 2385]
* generic/tclCmdMZ.c:
* generic/tclIO.c: Fix ANSI-style prototypes based on patch from
Ulrich Ring. [Bug: 2391]
* unix/Makefile.in: Need to make install-sh executable before
calling (with chmod +x). [Bug: 2413]
* tests/var.test:
* generic/tclVar.c: Fixed bug that caused a seg. fault when using
"array set a(b) {}", which is a bad array name anyway. Now the
"array set" command will return an error in this case. Added test
case and fixed existing test. [Bug: 2427]
|
|
|
|
| |
Added new code that modifies the channel in place.
|
|
|
|
| |
functions.
|
|
|
|
|
| |
a bad option is used. Because the fconfigure command is configurable (so
more option can be added), the error string is hardcoded.
|
| |
|
| |
|
|
|
|
|
|
| |
Simply replaced Tcl_RegisterChannel/UnregisterChannel with
Tcl_Preserve/Tcl_Release was all it took. Chanels are already
"eventually freed"
|
| |
|
| |
|
| |
|
|
|