summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorpatthoyts <patthoyts@users.sourceforge.net>2007-12-14 13:52:55 (GMT)
committerpatthoyts <patthoyts@users.sourceforge.net>2007-12-14 13:52:55 (GMT)
commit604a950260e29f0248794d40eb88e73a7cfc1465 (patch)
tree0fb1440464a2aff6f3994ac95b73760ebd2d3db6
parent8ae428cebfc46efcf400bdfa5bad949fd025bf15 (diff)
downloadtcl-604a950260e29f0248794d40eb88e73a7cfc1465.zip
tcl-604a950260e29f0248794d40eb88e73a7cfc1465.tar.gz
tcl-604a950260e29f0248794d40eb88e73a7cfc1465.tar.bz2
Fix for broken test on win2k with long machine name
-rw-r--r--ChangeLog6
-rw-r--r--tests/winFile.test7
2 files changed, 10 insertions, 3 deletions
diff --git a/ChangeLog b/ChangeLog
index 0568a20..2608749 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,7 +1,11 @@
+2007-12-14 Pat Thoyts <patthoyts@users.sourceforge.net>
+
+ * tests/winFile.test: Fixed tests for win2k with long machine name
+
2007-12-14 Pat Thoyts <patthoyts@users.sourceforge.net>
* win/nmakehlp.c: Support compilation with MSVC9 for AMD64.
- * win/makefile.vc:
+ * win/makefile.vc:
2007-12-13 Donal K. Fellows <donal.k.fellows@manchester.ac.uk>
diff --git a/tests/winFile.test b/tests/winFile.test
index c08cc20..0cefcb5 100644
--- a/tests/winFile.test
+++ b/tests/winFile.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: winFile.test,v 1.19 2006/10/01 09:51:05 patthoyts Exp $
+# RCS: @(#) $Id: winFile.test,v 1.20 2007/12/14 13:52:55 patthoyts Exp $
if {[catch {package require tcltest 2.0.2}]} {
puts stderr "Skipping tests in [info script]. tcltest 2.0.2 required."
@@ -95,6 +95,9 @@ proc cacls {fname args} {
# dir/q output:
# 2003-11-03 20:36 598 OCTAVIAN\benny filename.txt
+# Note this output from a german win2k machine:
+# 14.12.2007 14:26 30 VORDEFINIERT\Administratest.dat
+#
# Modified to cope with Msys environment and use ls -l.
proc getuser {fname} {
global env
@@ -112,7 +115,7 @@ proc getuser {fname} {
} else {
set dirtext [exec cmd /c dir /q [file nativename $fname]]
foreach line [split $dirtext "\n"] {
- if {[string match -nocase "* $tail" $line]} {
+ if {[string match -nocase "*$tail" $line]} {
set attrs [string range $line \
0 end-[string length $tail]]
regexp { [^ \\]+\\.*$} $attrs owner