diff options
author | Kevin B Kenny <kennykb@acm.org> | 2014-08-02 19:20:06 (GMT) |
---|---|---|
committer | Kevin B Kenny <kennykb@acm.org> | 2014-08-02 19:20:06 (GMT) |
commit | 2cfb3e19d01d75ab35c7cfeff3ec37c23dd34a4f (patch) | |
tree | 0de29565ab1dc6214ca6ef8e49eae3e7ee11608f /win/tclWinFile.c | |
parent | 54aa5c1f2d5513d45d1361a3615125a4810cc1c0 (diff) | |
parent | 3260faadc49ded6ca1d4aab4db21b5232cc647ff (diff) | |
download | tcl-2cfb3e19d01d75ab35c7cfeff3ec37c23dd34a4f.zip tcl-2cfb3e19d01d75ab35c7cfeff3ec37c23dd34a4f.tar.gz tcl-2cfb3e19d01d75ab35c7cfeff3ec37c23dd34a4f.tar.bz2 |
merge trunk
Diffstat (limited to 'win/tclWinFile.c')
-rw-r--r-- | win/tclWinFile.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/win/tclWinFile.c b/win/tclWinFile.c index ad4a5c4..fe84a26 100644 --- a/win/tclWinFile.c +++ b/win/tclWinFile.c @@ -2900,7 +2900,7 @@ TclNativeCreateNativeRep( WCHAR *nativePathPtr; const char *str; Tcl_Obj *validPathPtr; - int len; + size_t len; WCHAR *wp; if (TclFSCwdIsNative()) { @@ -2926,9 +2926,10 @@ TclNativeCreateNativeRep( Tcl_IncrRefCount(validPathPtr); } - str = Tcl_GetStringFromObj(validPathPtr, &len); + str = Tcl_GetString(validPathPtr); + len = validPathPtr->length; - if (strlen(str)!=len) { + if (strlen(str)!=(unsigned int)len) { /* String contains NUL-bytes. This is invalid. */ return 0; } |