diff --git a/versioncheck.php b/versioncheck.php index 770290ca7..e0ca71a52 100755 --- a/versioncheck.php +++ b/versioncheck.php @@ -24,6 +24,9 @@ if ($dataHandle) if ($argv[1] == "--cron") { + if (is_file('vrrd')) { echo("ERROR: 'vrrd' is not a directory!\n"); exit; } + if (is_dir('vrrd') && !is_writable('vrrd')) { echo("ERROR: I can not write in the 'vrrd' directory!\n"); exit; } + if (!is_dir('vrrd')) { mkdir('vrrd'); } $fd = fopen('vrrd/version.txt','w'); fputs($fd, "$major.$minor.$release"); fclose($fd);