From f6fdcc2953db152317a4d64649d21888c5b83d74 Mon Sep 17 00:00:00 2001 From: Nic Boet Date: Mon, 6 Jun 2022 22:51:34 -0500 Subject: [PATCH] Fix semaphore_tries on systems without System V This appears to be impacting systems without php System V semaphore support have_semaphore is not a boolean Signed-off-by: Nic Boet --- web/ajax/stream.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/web/ajax/stream.php b/web/ajax/stream.php index 02b78b238..3eff34fc8 100644 --- a/web/ajax/stream.php +++ b/web/ajax/stream.php @@ -25,7 +25,7 @@ while ( $semaphore_tries ) { usleep(100000); $semaphore_tries -= 1; } -if ($have_semaphore) { +if ($have_semaphore !== false) { if ( !($socket = @socket_create(AF_UNIX, SOCK_DGRAM, 0)) ) { ajaxError('socket_create() failed: '.socket_strerror(socket_last_error())); }