From ec0a19c5a691df2513a931e91e90dab238859d7f Mon Sep 17 00:00:00 2001 From: Andrew Dolgov Date: Fri, 4 Jul 2025 13:31:15 +0300 Subject: replace all instances of die() with print+exit because die() returns exit code 0 --- update.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'update.php') diff --git a/update.php b/update.php index 093b5ae82..362d056a3 100755 --- a/update.php +++ b/update.php @@ -141,7 +141,8 @@ } if (!isset($options['update-schema']) && Config::is_migration_needed()) { - die("Schema version is wrong, please upgrade the database (--update-schema).\n"); + print("Schema version is wrong, please upgrade the database (--update-schema).\n"); + exit(1); } Debug::set_enabled(true); @@ -188,8 +189,9 @@ // Try to lock a file in order to avoid concurrent update. if (!$lock_handle) { - die("error: Can't create lockfile ($lock_filename). ". + print("error: Can't create lockfile ($lock_filename). ". "Maybe another update process is already running.\n"); + exit(1); } if (isset($options["force-update"])) { -- cgit v1.2.3-54-g00ecf