diff --git a/src/s3fs.cpp b/src/s3fs.cpp index 14990be..822fe36 100644 --- a/src/s3fs.cpp +++ b/src/s3fs.cpp @@ -421,15 +421,13 @@ static int get_object_attribute(const char* path, struct stat* pstbuf, headers_t } // Check cache. - pisforce = (NULL != pisforce ? pisforce : &forcedir); - strpath = path; + pisforce = (NULL != pisforce ? pisforce : &forcedir); + (*pisforce) = false; + strpath = path; if(overcheck && string::npos != (Pos = strpath.find("_$folder$", 0))){ strpath = strpath.substr(0, Pos); strpath += "/"; } - if(pisforce){ - (*pisforce) = false; - } if(StatCache::getStatCacheData()->GetStat(strpath, pstat, pheader, overcheck, pisforce)){ StatCache::getStatCacheData()->ChangeNoTruncateFlag(strpath, add_no_truncate_cache); return 0;