summaryrefslogtreecommitdiffstats
path: root/generic
diff options
context:
space:
mode:
authordgp <dgp@users.sourceforge.net>2011-10-06 19:57:03 (GMT)
committerdgp <dgp@users.sourceforge.net>2011-10-06 19:57:03 (GMT)
commitc7659d156f438934f759f2535d156ccd9a3f0aed (patch)
treefee327faada8ab2b3957290ee46a5ad161c245af /generic
parentfedd2dbdda4b11265616856486e7c96296f3abcb (diff)
downloadtcl-c7659d156f438934f759f2535d156ccd9a3f0aed.zip
tcl-c7659d156f438934f759f2535d156ccd9a3f0aed.tar.gz
tcl-c7659d156f438934f759f2535d156ccd9a3f0aed.tar.bz2
Handle empty tail case to stop test failures.
Diffstat (limited to 'generic')
-rw-r--r--generic/tclPathObj.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/generic/tclPathObj.c b/generic/tclPathObj.c
index 168495e..7145592 100644
--- a/generic/tclPathObj.c
+++ b/generic/tclPathObj.c
@@ -1284,7 +1284,7 @@ TclNewFSPathObj(
Tcl_Obj *newPath, *tail = Tcl_NewStringObj(addStrRep, len);
Tcl_IncrRefCount(tail);
- if (addStrRep[0] == '~') {
+ if (len == 0 || addStrRep[0] == '~') {
newPath = AppendPath(dirPtr, tail);
Tcl_DecrRefCount(tail);
return newPath;