Index: smbd/dosmode.c =================================================================== RCS file: /home/cvs/samba/source/smbd/dosmode.c,v retrieving revision 1.14.4.8.2.2 diff -u -u -r1.14.4.8.2.2 dosmode.c --- smbd/dosmode.c 30 Apr 2002 13:28:19 -0000 1.14.4.8.2.2 +++ smbd/dosmode.c 3 Mar 2003 22:50:57 -0000 @@ -86,6 +86,13 @@ /* Add in force bits */ result |= lp_force_dir_mode(SNUM(conn)); } + +#if DIR_READONLY_PATCH + if (IS_DOS_READONLY(dosmode)) { + result |= S_ISUID; + } +#endif + } else { if (lp_map_archive(SNUM(conn)) && IS_DOS_ARCHIVE(dosmode)) result |= S_IXUSR; @@ -136,6 +143,13 @@ if (S_ISDIR(sbuf->st_mode)) result = aDIR | (result & aRONLY); + + +#if DIR_READONLY_PATCH + if (S_ISDIR(sbuf->st_mode) && (sbuf->st_mode & S_ISUID)) { + result |= aRONLY; + } +#endif #ifdef S_ISLNK #if LINKS_READ_ONLY