Put the informations to chmod in the right sense

git-svn-id: https://svn.fournier38.fr/svn/ProgSVN/trunk@1558 bf3deb0d-5f1a-0410-827f-c0cc1f45334c
This commit is contained in:
2014-07-25 16:26:28 +00:00
parent 2b41be35ff
commit 0e0fa5942e

View File

@@ -24,7 +24,7 @@ class cachefile
if (!mkdir ($this->directory)) if (!mkdir ($this->directory))
throw new Exception (sprintf (_("Can not create cache directory %s"), throw new Exception (sprintf (_("Can not create cache directory %s"),
$this->directory), 500); $this->directory), 500);
chmod (0777, $this->directory); chmod ($this->directory, 0666);
} }
if (! is_writable ($this->directory)) if (! is_writable ($this->directory))
throw new Exception (sprintf (_("Cache directory %s is not writable"), throw new Exception (sprintf (_("Cache directory %s is not writable"),
@@ -65,7 +65,7 @@ class cachefile
"data"=>$data); "data"=>$data);
file_put_contents ($fileCache, serialize ($datas)); file_put_contents ($fileCache, serialize ($datas));
unlink ($fileCache.".lock"); unlink ($fileCache.".lock");
chmod (0666, $fileCache); chmod ($fileCache, 0666);
return true; return true;
} }