Attachment "tclUnixFile.diff" to
ticket [823329ffff]
added by
das
2003-10-14 19:10:41.
Index: tclUnixFile.c
===================================================================
RCS file: /cvsroot/tcl/tcl/unix/tclUnixFile.c,v
retrieving revision 1.32
diff -u -r1.32 tclUnixFile.c
--- tclUnixFile.c 12 Feb 2003 18:57:52 -0000 1.32
+++ tclUnixFile.c 14 Oct 2003 12:10:09 -0000
@@ -369,8 +369,12 @@
/*
* readonly means that there are NO write permissions
* (even for user), but execute is OK for anybody
+ * OR that the user immutable flag is set (where supported).
*/
if (((types->perm & TCL_GLOB_PERM_RONLY) &&
+#if defined(HAVE_CHFLAGS) && defined(UF_IMMUTABLE)
+ !(buf.st_flags & UF_IMMUTABLE) &&
+#endif
(buf.st_mode & (S_IWOTH|S_IWGRP|S_IWUSR))) ||
((types->perm & TCL_GLOB_PERM_R) &&
(access(nativeEntry, R_OK) != 0)) ||