diff options
| author | nijtmans@users.sourceforge.net <jan.nijtmans> | 2014-11-03 12:44:55 (GMT) |
|---|---|---|
| committer | nijtmans@users.sourceforge.net <jan.nijtmans> | 2014-11-03 12:44:55 (GMT) |
| commit | 37cce8feb8dce8f7ea288fb42678107db79a9a0c (patch) | |
| tree | 7faccb16d2a2785049ba78869754cffc11a0ef41 /unix/tclUnixChan.c | |
| parent | 4ee42ca0708b4db24d639e63d97a2f9c43964d0c (diff) | |
| download | tcl-37cce8feb8dce8f7ea288fb42678107db79a9a0c.zip tcl-37cce8feb8dce8f7ea288fb42678107db79a9a0c.tar.gz tcl-37cce8feb8dce8f7ea288fb42678107db79a9a0c.tar.bz2 | |
Add test-case for previous commit, which shows that when trying to open a filename with invalid characters gives the right error-message. (same bug existed on UNIX too, which is now fixed)
Diffstat (limited to 'unix/tclUnixChan.c')
| -rw-r--r-- | unix/tclUnixChan.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/unix/tclUnixChan.c b/unix/tclUnixChan.c index 1d60340..89c9a27 100644 --- a/unix/tclUnixChan.c +++ b/unix/tclUnixChan.c @@ -1647,6 +1647,11 @@ TclpOpenFileChannel( native = Tcl_FSGetNativePath(pathPtr); if (native == NULL) { + if (interp != (Tcl_Interp *) NULL) { + Tcl_AppendResult(interp, "couldn't open \"", + TclGetString(pathPtr), "\": filename is invalid on this platform", + NULL); + } return NULL; } |
