true/yes setting. This is the default.
mode = map ACLs to Finder UARights and UNIX mode
From FR #73.
-
+* FIX: Fix a possible crash in cname() where cname_mtouname calls
+ dirlookup() where the curdir is freed because the dircache
+ detected a dev/inode cache difference and evicted the object
+ from the cache. Fixes bug #498.
+
Changes in 3.0.3
================
* UPD: afpd: Increase default DSI server quantum to 1 MB
return NULL; /* (1b) */
}
- if (lstat(cfrombstr(cdir->d_fullpath), &st) != 0) {
+ if (ostat(cfrombstr(cdir->d_fullpath), &st, vol_syml_opt(vol)) != 0) {
LOG(log_debug, logtype_afpd, "dircache(cnid:%u): {missing:\"%s\"}",
ntohl(cnid), cfrombstr(cdir->d_fullpath));
(void)dir_remove(vol, cdir);
}
if (cdir) {
- if (lstat(cfrombstr(cdir->d_fullpath), &st) != 0) {
+ if (ostat(cfrombstr(cdir->d_fullpath), &st, vol_syml_opt(vol)) != 0) {
LOG(log_debug, logtype_afpd, "dircache(did:%u,\"%s\"): {missing:\"%s\"}",
ntohl(dir->d_did), name, cfrombstr(cdir->d_fullpath));
(void)dir_remove(vol, cdir);
*
* @note If the passed ret->m_name is mangled, we'll demangle it
*/
-static int cname_mtouname(const struct vol *vol, const struct dir *dir, struct path *ret, int toUTF8)
+static int cname_mtouname(const struct vol *vol, struct dir *dir, struct path *ret, int toUTF8)
{
static char temp[ MAXPATHLEN + 1];
char *t;
/* check for OS X mangled filename :( */
t = demangle_osx(vol, ret->m_name, dir->d_did, &fileid);
+
+ if (curdir == NULL) {
+ /* demangle_osx() calls dirlookup() which might have clobbered curdir */
+ movecwd(vol, dir);
+ }
+
LOG(log_maxdebug, logtype_afpd, "cname_mtouname('%s',did:%u) {demangled:'%s', fileid:%u}",
ret->m_name, ntohl(dir->d_did), t, ntohl(fileid));