From: Ralph Boehme Date: Wed, 24 Sep 2014 13:25:09 +0000 (+0200) Subject: afpd: umask handling, bug #576 X-Git-Url: https://arthur.barton.de/gitweb/?p=netatalk.git;a=commitdiff_plain;h=d517632b2d4ef26ea7bbd12794d1cf0709f33542 afpd: umask handling, bug #576 Authored-by: Rasmus Borup Hansen Reviewed-by: Ralph Boehme --- diff --git a/NEWS b/NEWS index 15f1fdff..3da15603 100644 --- a/NEWS +++ b/NEWS @@ -7,6 +7,7 @@ Changes in 3.1.7 to the other Netatalk processes, bug #579 * FIX: afpd: Solaris locking problem, bug #559 * FIX: Handling of malformed UTF8 strings, bug #524 +* FIX: afpd: umask handling, bug #576 Changes in 3.1.6 ================ diff --git a/etc/afpd/unix.c b/etc/afpd/unix.c index a42a6ab9..e928fda9 100644 --- a/etc/afpd/unix.c +++ b/etc/afpd/unix.c @@ -229,7 +229,8 @@ int setdirunixmode(const struct vol *vol, char *name, mode_t mode) LOG(log_debug, logtype_afpd, "setdirunixmode('%s', mode:%04o) {v_dperm:%04o}", fullpathname(name), mode, vol->v_dperm); - mode |= (vol->v_dperm | DIRBITS) & ~vol->v_umask; + mode |= vol->v_dperm | DIRBITS; + mode &= ~vol->v_umask; if (dir_rx_set(mode)) { /* extending right? dir first then .AppleDouble in rf_setdirmode */