diff options
-rw-r--r-- | mod/import.php | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/mod/import.php b/mod/import.php index 4542ef7a0..02f4133d5 100644 --- a/mod/import.php +++ b/mod/import.php @@ -38,6 +38,15 @@ function import_post(&$a) { if($src) { + + // This is OS specific and could also fail if your tmpdir isn't very large + // mostly used for Diaspora which exports gzipped files. + + if(strpos($filename,'.gz')){ + @rename($src,$src . '.gz'); + @system('gunzip ' . escapeshellarg($src . '.gz')); + } + if($filesize) { $data = @file_get_contents($src); } |