From: Tobias Diekershoff Date: Sat, 19 Sep 2015 11:53:13 +0000 (+0200) Subject: Merge pull request #1893 from annando/1509-lockpath X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=0a41a8127b39c08ddc0bed9f299e14895885e040;hp=976a2be1f7f3a12c17fb572c418366d36299f545;p=friendica.git Merge pull request #1893 from annando/1509-lockpath Avoiding errors when checking for the lockpath --- diff --git a/boot.php b/boot.php index 7451891fef..e2eed38ebf 100644 --- a/boot.php +++ b/boot.php @@ -1811,7 +1811,11 @@ function get_lockpath() { if ($temppath != "") { $lockpath = $temppath."/lock"; - mkdir($lockpath); + + if (!is_dir($lockpath)) + mkdir($lockpath); + elseif (!is_writable($lockpath)) + $lockpath = $temppath; if (is_dir($lockpath) AND is_writable($lockpath)) { set_config("system", "lockpath", $lockpath);