Tcl Source Code

Check-in [c286356bd3]
Login
Bounty program for improvements to Tcl and certain Tcl packages.
Tcl 2019 Conference, Houston/TX, US, Nov 4-8
Send your abstracts to [email protected]
or submit via the online form by Sep 9.

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Another Preserve/Release on channels is needed during IO finalization.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: c286356bd3eee1033ad77028a6060541c1876c04
User & Date: dgp 2014-08-02 04:36:39
Context
2014-08-04
14:02
merge trunk check-in: 67c1a8899a user: ferrieux tags: tip-429
13:36
Add tclsh.exe.manifest.in to the distribution check-in: ed24f583f4 user: dgp tags: trunk
2014-08-02
19:20
merge trunk check-in: 63ed148e71 user: kbk tags: dkf-improved-disassembler
04:50
merge trunk check-in: f4c5f4c7b0 user: dgp tags: dgp-refactor
04:38
merge trunk check-in: c8994555bf user: dgp tags: core-8-6-2-rc
04:36
Another Preserve/Release on channels is needed during IO finalization. check-in: c286356bd3 user: dgp tags: trunk
04:25
Another Preserve/Release on channels is needed during IO finalization. check-in: c22cc5859b user: dgp tags: core-8-5-branch
2014-08-01
20:07
Addition of a cast in tclWinFile.c to match types in a comparison, and fix of a TRACE string literal... check-in: f8304cc503 user: andreask tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to generic/tclIO.c.

622
623
624
625
626
627
628

629
630
631
632
633
634
635
...
680
681
682
683
684
685
686

687
688
689
690
691
692
693
	/*
	 * We've found a live (or bg-closing) channel. Close it.
	 */

	if (active) {


	    /*
	     * TIP #398:  by default, we no  longer set the  channel back into
             * blocking  mode.  To  restore  the old  blocking  behavior,  the
             * environment variable  TCL_FLUSH_NONBLOCKING_ON_EXIT must be set
             * and not be "0".
	     */
            if (doflushnb) {
................................................................................
		 * mark the channel with CHANNEL_DEAD to prevent any further
		 * IO operations on it.
		 */

		chanPtr->instanceData = NULL;
		SetFlag(statePtr, CHANNEL_DEAD);
	    }

	}
    }

    TclpFinalizeSockets();
    TclpFinalizePipes();
}
 






>







 







>







622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
...
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
	/*
	 * We've found a live (or bg-closing) channel. Close it.
	 */

	if (active) {

	    TclChannelPreserve((Tcl_Channel)chanPtr);
	    /*
	     * TIP #398:  by default, we no  longer set the  channel back into
             * blocking  mode.  To  restore  the old  blocking  behavior,  the
             * environment variable  TCL_FLUSH_NONBLOCKING_ON_EXIT must be set
             * and not be "0".
	     */
            if (doflushnb) {
................................................................................
		 * mark the channel with CHANNEL_DEAD to prevent any further
		 * IO operations on it.
		 */

		chanPtr->instanceData = NULL;
		SetFlag(statePtr, CHANNEL_DEAD);
	    }
	    TclChannelRelease((Tcl_Channel)chanPtr);
	}
    }

    TclpFinalizeSockets();
    TclpFinalizePipes();
}