From 3bb1d29e9f77f025575047eab1cd1d3d4565674e Mon Sep 17 00:00:00 2001 From: Franco Fichtner Date: Wed, 1 Apr 2015 09:18:33 +0200 Subject: [PATCH] inc: remove unused shmop plugin usage --- src/etc/inc/util.inc | 20 -------------------- src/etc/rc.php_ini_setup | 2 -- 2 files changed, 22 deletions(-) diff --git a/src/etc/inc/util.inc b/src/etc/inc/util.inc index 87de93624..36b377255 100644 --- a/src/etc/inc/util.inc +++ b/src/etc/inc/util.inc @@ -155,26 +155,6 @@ function send_event($cmd) return $backend->sendEvent("{$cmd}"); } -function refcount_init($reference) { - $shmid = @shmop_open($reference, "c", 0644, 10); - @shmop_write($shmid, str_pad("0", 10, "\x0", STR_PAD_RIGHT), 0); - @shmop_close($shmid); -} - - -function refcount_read($reference) { - /* This function just reads the current value of the refcount for information. */ - /* There is no need for locking. */ - $shmid = @shmop_open($reference, "a", 0, 0); - if (!$shmid) { - log_error(gettext("Could not open shared memory for read {$reference}")); - return -1; - } - $shm_data = @shmop_read($shmid, 0, 10); - @shmop_close($shmid); - return $shm_data; -} - function is_module_loaded($module_name) { $module_name = str_replace(".ko", "", $module_name); $running = 0; diff --git a/src/etc/rc.php_ini_setup b/src/etc/rc.php_ini_setup index 9c11c657b..60279c6c4 100755 --- a/src/etc/rc.php_ini_setup +++ b/src/etc/rc.php_ini_setup @@ -59,8 +59,6 @@ PHPMODULES="$PHPMODULES suhosin" PHPMODULES="$PHPMODULES ctype" # firewall_rules_edit.php PHPMODULES="$PHPMODULES mbstring" -# Synchronization primitives -PHPMODULES="$PHPMODULES shmop" # Page compression PHPMODULES="$PHPMODULES zlib" # SQLlite & Database