summaryrefslogtreecommitdiffstats
path: root/win/tclWinChan.c
Commit message (Collapse)AuthorAgeFilesLines
* Style improvements - invoking callbacks without visual junk.dkf2008-10-261-4/+4
|
* * win/tclWinChan.c: Fix minor compiler warnings whennijtmans2008-10-141-2/+2
| | | | | | | * win/tclWinDde.c: compiling wit -Wwrite-strings * win/tclWinInit.c: * win/tclWinReg.c: * win/tclWinSerial.c:
* * win/tclWinChan.c (FileWideSeekProc): Accepted a patch byandreas_kupries2008-05-231-2/+2
| | | | | | | | | | | | Alexandre Ferrieux <ferrieux@users.sourceforge.net> to fix the [Bug 1965787]. 'tell' now works for locations > 2 GB as well instead of going negative. * generic/tclIO.c (Tcl_SetChannelBufferSize): Accepted a patch by * tests/io.test: Alexandre Ferrieux <ferrieux@users.sourceforge.net> * tests/chanio.test: to fix the [Bug 1969953]. Buffersize outside of the supported range are now clipped to nearest boundary instead of ignored.
* Get rid of pre-C89-isms (esp. CONST vs const).dkf2008-04-271-20/+19
|
* Complete the purge of K&R function definitions from manually-written code.dkf2007-04-161-6/+8
|
* * win/tclWinChan.c [Bug 819667] Improve logic for identifying COMhobbs2006-08-301-51/+52
| | | | ports.
* * doc/CrtChannel.3: Added TCL_CHANNEL_VERSION_5, made itandreas_kupries2006-03-271-2/+2
| | | | | | | | | | | | | | * generic/tcl.h: the version where the "truncateProc" * generic/tclIO.c: is defined at, and moved all channel * generic/tclIOGT.c: drivers of Tcl to v5. * generic/tclIORChan.c: * unix/tclUnixChan.c: * unix/tclUnixPipe.c: * win/tclWinChan.c: * win/tclWinConsole.c: * win/tclWinPipe.c: * win/tclWinSerial.c: * win/tclWinSock.c:
* Export stubs for libtommath; fix mingw compiler warningsKevin B Kenny2005-12-131-6/+7
|
* ANSIfydkf2005-11-041-72/+72
|
* Getting more systematic about styledkf2005-07-241-254/+257
|
* bug 1225957Kevin B Kenny2005-06-231-105/+97
|
* D'oh. [Bug 1217017]dkf2005-06-081-2/+2
|
* Added (untested!) implementation of truncation for Windowsdkf2005-06-071-1/+74
|
* Merged kennykb-numerics-branch back to the head; TIPs 132 and 232Kevin B Kenny2005-05-101-1/+1
|
* TIP#218 IMPLEMENTATIONandreas_kupries2005-01-271-76/+42
| | | | | | | | | | | | | | | | | | | | * generic/tclDecls.h: Regenerated from tcl.decls. * generic/tclStubInit.c: * doc/CrtChannel.3: Documentation of extended API, * generic/tcl.decls: extended testsuite, and * generic/tcl.h: implementation. Removal of old * generic/tclIO.c: driver-specific TclpCut/Splice * generic/tclInt.h: functions. Replaced with generic * tests/io.test: thread-action calls through the * unix/tclUnixChan.c: new hooks. Update of all builtin * unix/tclUnixPipe.c: channel drivers to version 4. * unix/tclUnixSock.c: Windows drivers extended to * win/tclWinChan.c: manage thread state in a thread * win/tclWinConsole.c: action handler. * win/tclWinPipe.c: * win/tclWinSerial.c: * win/tclWinSock.c:
* * win/tclWinChan.c (FileCloseProc): Invokemdejong2005-01-191-1/+20
| | | | | | | | | TclpCutFileChannel() to remove a FileInfo from the thread local list before deallocating it. This should have been done via an earlier call to Tcl_CutChannel, but I was running into a crash in the next call to Tcl_CutChannel during the IO finalization stage.
* Whitespace police and other style fixesdkf2004-10-201-233/+216
|
* Add braces to if bodiesdkf2004-10-061-67/+64
| | | | Also simplify the SEH-code by reducing the number of #ifdef's...
* * win/tclWin32Dll.c (DllMain, _except_dllmain_detach_handler,mdejong2004-06-211-7/+35
| | | | | | | | | | | | | | | TclpCheckStackSpace, _except_checkstackspace_handler, TclWinCPUID, _except_TclWinCPUID_detach_handler): * win/tclWinChan.c (Tcl_MakeFileChannel, _except_makefilechannel_handler): * win/tclWinFCmd.c (DoRenameFile, _except_dorenamefile_handler, DoCopyFile, _except_docopyfile_handler): Rework pushing of exception handler function pointer so that compiling with gcc -O3 works. Remove empty function call to avoid compiler warning. Mark the DllMain function as noinline to avoid compiler error from duplicated asm labels in generated code.
* (Tcl_MakeFileChannel) : Case for CloseHandle returning zero and notdavygrvy2004-04-231-7/+13
| | | | | throwing a RaiseException(EXCEPTION_INVALID_HANDLE) now being done.
* All uses of 'panic' (the macro) changeddavygrvy2003-12-241-9/+9
| | | | | | | to 'Tcl_Panic' (the function). The #define of panic in tcl.h clearly states it is deprecated in the comments. [Patch 865264]
* prefer Tcl_LongAsWide and Tcl_WideAsLong for casts.davygrvy2003-12-131-5/+5
|
* Win32's SetFilePointer() takes LONGs not DWORDs. Redid local varsdavygrvy2003-12-131-11/+11
| | | | to avoid all casting except where truly required.
* * generic/tclIO.c (Tcl_CutChannel, Tcl_SpliceChannel):mdejong2003-01-261-10/+93
| | | | | | | | | | | | | | | | Invoke TclpCutFileChannel and TclpSpliceFileChannel. * generic/tclInt.h: Declare TclpCutFileChannel and TclpSpliceFileChannel. * unix/tclUnixChan.c (FileCloseProc, TclpOpenFileChannel, Tcl_MakeFileChannel, TclpCutFileChannel, TclpSpliceFileChannel): Implement thread load data cut and splice for file channels. This avoids an invalid memory ref when compiled with -DDEPRECATED. * win/tclWinChan.c (FileCloseProc, TclpCutFileChannel, TclpSpliceFileChannel): Implement thread load data cut and splice for file channels. This avoids an invalid memory ref that was showing up in the thread extension.
* * win/tclWin32Dll.c (TclpCheckStackSpace, squelch_warnings):mdejong2003-01-251-39/+55
| | | | | | | | | | | | | | * win/tclWinChan.c (Tcl_MakeFileChannel, squelch_warnings): * win/tclWinFCmd.c (DoRenameFile, DoCopyFile, squelch_warnings): Re-implement inline ASM SEH handlers for gcc. The esp and ebp registers are now saved on the stack instead of in global variables so that the code is thread safe. Add additional checks when TCL_MEM_DEBUG is defined to be sure the values were recovered from the stack properly. Remove squelch_warnings functions and add a dummy call in the handler methods to squelch compiler warnings.
* * win/tclWin32Dll.c (squelch_warnings): Squelchmdejong2003-01-161-1/+16
| | | | | | | | | | | | | | | | | | | | | | compiler warnings from SEH ASM code. * win/tclWinChan.c (squelch_warnings): Squelch compiler warnings from SEH ASM code. * win/tclWinDde.c: Add casts to avoid compiler warnings. Pass pointer to DWORD instead of int to avoid compiler warnings. * win/tclWinFCmd.c (squelch_warnings): Add casts and fixup decls to avoid compiler warnings. Squelch compiler warnings from SEH ASM code. * win/tclWinFile.c: Add casts and fixup decls to avoid compiler warnings. Remove unused variable. * win/tclWinNotify.c: Declare as DWORD instead of int to avoid compiler warning. * win/tclWinReg.c: Add casts to avoid compiler warning. Fix assignment in if expression bug. * win/tclWinSerial.c: Add casts to avoid compiler warnings. Remove unused variable. * win/tclWinSock.c: Add casts and fixup decls to avoid compiler warnings.
* Fix mingw build problems and compiler warnings.mdejong2003-01-141-4/+4
| | | | | | | | | | | | | | | | * generic/tcl.h: Add if defined(__MINGW32__) check to code that sets the TCL_WIDE_INT_TYPE and TCL_LL_MODIFIER. * generic/tclClock.c (FormatClock): Don't define savedTimeZone and savedTZEnv if we are not going to use them. * generic/tclEnv.c: Add cast to avoid warning. * win/tclWinChan.c: Use DWORD instead of int to avoid compiler warning. * win/tclWinThrd.c: Only define allocLock, allocLockPtr, and dataKey when TCL_THREADS is defined. This avoid a compiler warning about unused variables.
* * win/tclWinChan.c (Tcl_MakeFileChannel): return ofdavygrvy2002-11-271-2/+2
| | | | DuplicateHandle() incorrectly used [Bug 618852].
* * generic/tclEvent.c (TclInExit, TclInThreadExit):mdejong2002-11-071-4/+4
| | | | | | | | | | | | | | | 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.
* fs cleanupvincentdarley2002-07-081-24/+4
|
* TIP#91 implementation; makes old style channels binary compatible withdkf2002-05-241-4/+84
| | | | new TIP#72-enabled Tcl. See http://purl.org/tcl/tip/91 for details.
* memory cleanupvincentdarley2002-05-131-8/+9
|
* * win/configure: Regen.mdejong2002-03-151-1/+53
| | | | | | | | | | | | | | * win/configure.in: Add configure time test for SEH support in the compiler. * win/tclWin32Dll.c (ESP, EBP, TclpCheckStackSpace, _except_checkstackspace_handler): * win/tclWinChan.c (ESP, EBP, Tcl_MakeFileChannel, _except_makefilechannel_handler): * win/tclWinFCmd.c (ESP, EBP, DoRenameFile, _except_dorenamefile_handler, DoCopyFile, _except_docopyfile_handler): Implement SEH support under gcc using inline asm. Tcl and Tk should now compile with Mingw 1.1. [Patch 525746]
* TIP#72 implementation. See ChangeLog for details.dkf2002-02-151-16/+20
| | | | | 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.
* * Overlooked callers of Tcl_FSGetNativePathdgp2002-01-181-2/+2
|
* * 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-3/+3
| | | | | | | | | | | 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.
* * win/tclWinChan.c:hobbs2001-10-151-1/+15
| | | | | | * win/tclWinPort.h: * win/tclWinSerial.c: added TIP #35 Windows enhancements for serial configuration. [Patch #438509] (schroedter)
* * All the changes below serve to fix bug [219148] which reports aandreas_kupries2001-09-071-3/+47
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 80x performance hit for file I/O on Win* systems. On my system it was closer to a 120x hit. Problem report by Uwe Traum <no email address available>. The fix goes like this: The obstacle is 'FlushFileBuffers', executed whenever Tcl writes data to the OS, as Tcl has to wait for the disk to complete I/O, and disks are slow. We remove that obstacle. This opens another problem, [file size] reports back wrong numbers. So for [file size] we add the call back in. As optimization we keep track of the channels which were written to and flush only these. * win/tclWinFile.c (TclpObjStat): Added a call to 'TclWinFlushDirtyChannels'. This ensures that [file size] and related commands report the correct size of a file even if Tcl has recently written to it. Unixoid OS's always report the correct size even for files with pending data, but Win* syssystem don't. They only report what is actually on disk. * win/tclWinInt.h: Added declaration of 'TclWinFlushDirtyChannels', making it available to other parts of the tcl core. * win/tclWinChan.c (TclWinFlushDirtyChannels): New, internal, procedure. Goes through the list of open file channels and forces the OS to flush its file buffers for all which were written to since the last call of this function. This is an expensive operation as Tcl has to wait for the OS to complete actual writes to the disk. (FileInfo): Added dirty flag required by the procedure above. (FileOutputProc): Removed flushing of file buffers, setting the dirty flag instead. This means that the previously incurred delays do not happen anymore. (TclWinOpenFileChannel): Added initialization of 'dirty' flag.
* filesystemvincentdarley2001-08-301-15/+11
|
* 2000-10-06 David Gravereaux <davygrvy@ajubasolutions.com>davidg2000-10-061-22/+53
| | | | | | | * win/tclWinChan.c: moved Win2K bug case test with GetStdHandle() from TclpGetDefaultStdChannel into Tcl_MakeFileChannel to enable a more general method in detecting invalid OS handles rather than just a specific known case. [BUG: 5971]
* up-port of the stacked channel implementation rewrite in 8.3.2 tohobbs2000-09-281-2/+6
| | | | 8.4a2 code base, merged in with some existing new 8.4a2 features.
* Win2K OS bug with GetStdHandle(STD_OUTPUT_HANDLE) returningdavidg2000-07-181-5/+19
| | | | | 0x00010001 instead of INVALID_HANDLE_VALUE for WinMain apps. Added a new test case to catch it.
* * library/dde1.1/pkgIndex.tcl:hobbs2000-04-201-2/+2
| | | | | | | | | | | * library/reg1.0/pkgIndex.tcl: * win/tclWinChan.c: * win/tclWinThrd.c: converted CRLF to LF the */tcl.hpj.in files were not converted, as it confuses hcw locally. [Bug: 5096] * win/Makefile.in: expanded cleanup or help files * doc/Thread.3: minor macro cleanup
* * win/tclWin32Dll.c:hobbs1999-12-091-9/+5
| | | | | | | | | | | | | | | * win/tclWinChan.c: * win/tclWinFCmd.c: * win/tclWinInit.c: * win/tclWinPipe.c: * win/tclWinSock.c: removed all code that supported Win32s. It was no longer officially supported, and likely didn't work anyway. * win/makefile.vc: removed 16 bit stuff, cleaned up. * win/tcl16.rc: * win/tclWin16.c: * win/winDumpExts.c: these files have been removed from the source tree (no longer necessary to build) * win/aclocal.m4: made it just include tcl.m4
* * win/tclWinChan.c: Allow tcl to open CON and NUL, even for stdredman1999-07-301-15/+18
| | | | | | channels. Checking for bad/unusable std channels was moved to Tk since its only purpose was to check whether to use the Tk Console Window for the std channels. [Bug: 2393 2392 2209 2458]
* Merged changes from scriptics-tclpro-1-3-b2 branchstanton1999-05-221-5/+25
|
* merged tcl 8.1 branch back into the main trunkstanton1999-04-161-361/+249
|
* Merged stubs changes into mainline for 8.0stanton1999-03-101-1/+2
|
* Updated the version to 8.0.5.rjohnson1999-01-041-1/+4
|