summaryrefslogtreecommitdiffstats
path: root/lib/filestorage/local.php
diff options
context:
space:
mode:
Diffstat (limited to 'lib/filestorage/local.php')
-rw-r--r--lib/filestorage/local.php4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/filestorage/local.php b/lib/filestorage/local.php
index 688501aee90..bd757f52ce7 100644
--- a/lib/filestorage/local.php
+++ b/lib/filestorage/local.php
@@ -86,6 +86,10 @@ class OC_Filestorage_Local extends OC_Filestorage{
return $this->delTree($path);
}
public function rename($path1,$path2){
+ if (!$this->is_writable($path1)) {
+ OC_Log::write('core','unable to rename, file is not writable : '.$path1,OC_Log::ERROR);
+ return false;
+ }
if(! $this->file_exists($path1)){
OC_Log::write('core','unable to rename, file does not exists : '.$path1,OC_Log::ERROR);
return false;