diff options
author | hobbs <hobbs> | 2004-02-17 23:46:52 (GMT) |
---|---|---|
committer | hobbs <hobbs> | 2004-02-17 23:46:52 (GMT) |
commit | 9f2e98f7594d2b4c92cad8f0db2d81b648d9d05f (patch) | |
tree | 57a631b8cb81d611eaec8f4a1ac52d4836a046ec /tests/unixInit.test | |
parent | 4900778b2971531fabc6662ad41b842f0702992b (diff) | |
download | tcl-9f2e98f7594d2b4c92cad8f0db2d81b648d9d05f.zip tcl-9f2e98f7594d2b4c92cad8f0db2d81b648d9d05f.tar.gz tcl-9f2e98f7594d2b4c92cad8f0db2d81b648d9d05f.tar.bz2 |
* tests/unixInit.test: unixInit-7.1
* unix/tclUnixInit.c (TclpInitPlatform): ensure the std fds exist
to prevent crash condition [Bug #772288]
Diffstat (limited to 'tests/unixInit.test')
-rw-r--r-- | tests/unixInit.test | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/tests/unixInit.test b/tests/unixInit.test index f7b5a39..0225e3c 100644 --- a/tests/unixInit.test +++ b/tests/unixInit.test @@ -10,7 +10,7 @@ # See the file "license.terms" for information on usage and redistribution # of this file, and for a DISCLAIMER OF ALL WARRANTIES. # -# RCS: @(#) $Id: unixInit.test,v 1.30.2.3 2003/11/10 20:32:34 dgp Exp $ +# RCS: @(#) $Id: unixInit.test,v 1.30.2.4 2004/02/17 23:46:53 hobbs Exp $ package require tcltest 2 namespace import -force ::tcltest::* @@ -354,6 +354,19 @@ test unixInit-5.1 {Tcl_Init} {emptyTest unixOnly} { test unixInit-6.1 {Tcl_SourceRCFile} {emptyTest unixOnly} { } {} +test unixInit-7.1 {closed standard channel: Bug 772288} -body { + set tclsh [interpreter] + makeFile {puts [open /dev/null]} crash.tcl + makeFile [subst -nocommands { + close stdin + exec $tclsh crash.tcl + }] crashtest.tcl + exec $tclsh crashtest.tcl +} -cleanup { + removeFile crash.tcl + removeFile crashtest.tcl +} -returnCodes 0 + # cleanup if {[info exists oldlibrary]} { set env(TCL_LIBRARY) $oldlibrary |