Roxen.git / server / modules / filesystems / filesystem.pike

version» Context lines:

Roxen.git/server/modules/filesystems/filesystem.pike:375:    privs=Privs(X, uid->uid(), uid->gid() ); \    }      mixed stat_file( string f, RequestID id )   {    Stat fs;       FILESYSTEM_WERR("stat_file for \""+f+"\"" +    (id->misc->internal_get ? " (internal)" : ""));    -  f = path + encode_path(f); +  string norm_f = real_path(f, id); +  if (!norm_f) return 0;    -  if (FILTER_INTERNAL_FILE (f, id)) -  return 0; -  +     if(stat_cache && !id->pragma["no-cache"] && -  (fs=cache_lookup("stat_cache",f))) +  (fs = cache_lookup("stat_cache", norm_f)))    return fs[0];    object privs;    SETUID_NT("Statting file");       /* No security currently in this function */ -  fs = file_stat(f); +  fs = file_stat(norm_f);    privs = 0;    if(!stat_cache) return fs; -  cache_set("stat_cache", f, ({fs})); +  cache_set("stat_cache", norm_f, ({fs}));    return fs;   }      //! Normalize DAVLock path identifier.   string resource_id(string path, RequestID|int(0..0) id)   {    if ((< "Darwin", "Win32" >)[uname()->sysname]) {    return ::resource_id(lower_case(path), id);    }    return ::resource_id(path, id);