summaryrefslogtreecommitdiffstats
path: root/usr/local/www/firewall_shaper_queues.php
diff options
context:
space:
mode:
authorErmal Luçi <eri@pfsense.org>2009-05-08 18:42:37 +0000
committerErmal Luçi <eri@pfsense.org>2009-05-08 18:42:37 +0000
commit0027de0a544438f146cfc94f005fd6f4ba9f94d7 (patch)
tree3f97d22951284c2a7b02563ecdbb0fd126b46f15 /usr/local/www/firewall_shaper_queues.php
parent89e6e210158ca4ca24d2ddbc02ccab72175875a5 (diff)
downloadpfsense-0027de0a544438f146cfc94f005fd6f4ba9f94d7.zip
pfsense-0027de0a544438f146cfc94f005fd6f4ba9f94d7.tar.gz
* Create two new functions lock($subsystem)/unlock() to have more reliable locking using semaphores.
This function can sleep till the resource is free and can help find not well behaving code. * Remove most of the config_lock/config_unlock logics on the whole scripts/pages it is an abuse of this. If any sybsytem wants to lock can do so with its own lock. * Lock the config when doing a filter reload to avoid parallell recursion on this function, since it is not reentrant. This compenstates for the removal of lock aquiring from the scripts/pages. * config_lock/config_unlock are now compate shims that do nothing. They are preserved since packages 'abuse' them too.
Diffstat (limited to 'usr/local/www/firewall_shaper_queues.php')
-rwxr-xr-xusr/local/www/firewall_shaper_queues.php9
1 files changed, 3 insertions, 6 deletions
diff --git a/usr/local/www/firewall_shaper_queues.php b/usr/local/www/firewall_shaper_queues.php
index 342083e..3495fdf 100755
--- a/usr/local/www/firewall_shaper_queues.php
+++ b/usr/local/www/firewall_shaper_queues.php
@@ -145,13 +145,10 @@ if ($_GET) {
if ($_POST['apply']) {
write_config();
- $retval = 0;
- $savemsg = get_std_save_message($retval);
+ $retval = 0;
/* Setup pf rules since the user may have changed the optimization value */
-
- config_lock();
- $retval = filter_configure();
- config_unlock();
+ $retval = filter_configure();
+ $savemsg = get_std_save_message($retval);
if (stristr($retval, "error") <> true)
$savemsg = get_std_save_message($retval);
else
OpenPOWER on IntegriCloud