summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorErich Eckner <git@eckner.net>2020-04-14 09:38:33 +0200
committerErich Eckner <git@eckner.net>2020-04-14 09:38:33 +0200
commit31e575401080b381a6132d3835db54e5e7b3d121 (patch)
tree2894f880e0efdc56aca82ee37a9851bd82fd6154
parenta441a330e70e73b88ce07ad502ac6e515f422e14 (diff)
downloadsourceMirror-31e575401080b381a6132d3835db54e5e7b3d121.tar.xz
mirror.php: ignore stat===false
-rw-r--r--mirror.php7
1 files changed, 4 insertions, 3 deletions
diff --git a/mirror.php b/mirror.php
index 61f81f9..194df0e 100644
--- a/mirror.php
+++ b/mirror.php
@@ -68,10 +68,11 @@
if (file_exists($pfad)) {
$stat = stat($pfad);
- if ($stat['size'] == 0)
- unlink($pfad);
+ if ($stat !== false) {
+ if ($stat['size'] == 0)
+ unlink($pfad);
+ }
}
-
if (! file_exists($pfad)) {
passthru(
"mkdir -p '".dirname($pfad)."'; ".