From 1c82191f8c3a5bc735dd8cae9f5082bda42fa826 Mon Sep 17 00:00:00 2001 From: Pavel Shevaev Date: Tue, 6 May 2025 16:07:56 +0300 Subject: [PATCH] gamectl_unlock(..) now unsets env.variable and ignores any error during unlink --- lock.inc.php | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/lock.inc.php b/lock.inc.php index 7b84b2d..2a3b37b 100644 --- a/lock.inc.php +++ b/lock.inc.php @@ -64,5 +64,13 @@ function gamectl_unlock() $lock = $GAME_ROOT . '/gamectl.lock'; if(file_exists($lock)) - unlink($lock); + { + try + { + unlink($lock); + } + catch(\Exception $e) {} + } + + putenv("GAMECTL_IN_LOCK"); }