summaryrefslogtreecommitdiffstats
path: root/tests/io.test
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2011-10-11 13:29:46 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2011-10-11 13:29:46 (GMT)
commitf01a35a8bc7861d7942f77237f10ddd075ac2a4d (patch)
tree08c1382b370bca40dc144a4669cfa2315a71b7ae /tests/io.test
parent78ffbba4305695c97a8aaf20492ba363d7533f19 (diff)
parent0d8495931b3744280c05530401801c86da4c0a3a (diff)
downloadtcl-f01a35a8bc7861d7942f77237f10ddd075ac2a4d.zip
tcl-f01a35a8bc7861d7942f77237f10ddd075ac2a4d.tar.gz
tcl-f01a35a8bc7861d7942f77237f10ddd075ac2a4d.tar.bz2
[Bug 2935503] Incorrect mode field returned by file stat command
Diffstat (limited to 'tests/io.test')
-rw-r--r--tests/io.test8
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/io.test b/tests/io.test
index 129d741..28e847e 100644
--- a/tests/io.test
+++ b/tests/io.test
@@ -5203,18 +5203,18 @@ test io-40.1 {POSIX open access modes: RDWR} {
close $f
set x
} {zzy abzzy}
-test io-40.2 {POSIX open access modes: CREAT} {unix} {
+test io-40.2 {POSIX open access modes: CREAT} {
file delete $path(test3)
- set f [open $path(test3) {WRONLY CREAT} 0600]
+ set f [open $path(test3) {WRONLY CREAT} 0o666]
file stat $path(test3) stats
- set x [format "0%o" [expr $stats(mode)&0o777]]
+ set x [format "0o%o" [expr $stats(mode)&0o777]]
puts $f "line 1"
close $f
set f [open $path(test3) r]
lappend x [gets $f]
close $f
set x
-} {0600 {line 1}}
+} {0o666 {line 1}}
test io-40.3 {POSIX open access modes: CREAT} {unix umask} {
# This test only works if your umask is 2, like ouster's.
file delete $path(test3)