]> git.ipfire.org Git - people/pmueller/ipfire-2.x.git/commitdiff
ids.cgi: Make the page lock in oinkmaster_web() function optional.
authorStefan Schantl <stefan.schantl@ipfire.org>
Fri, 22 Apr 2022 03:44:23 +0000 (05:44 +0200)
committerStefan Schantl <stefan.schantl@ipfire.org>
Fri, 22 Apr 2022 03:44:23 +0000 (05:44 +0200)
This allows to call and release the page lock manually.

Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
html/cgi-bin/ids.cgi

index 3ee66e06b16f52643144c3b7d6c67d7e60fd7824..c961c91bf8e5228edc350b3be1602f9188b0ae0b 100644 (file)
@@ -1867,10 +1867,14 @@ sub _close_working_notice () {
 ## oinkmaster function, but provides a lot of HTML formated status output.
 #
 sub oinkmaster_web () {
+       my ($nolock) = @_;
+
        my @enabled_providers = &IDS::get_enabled_providers();
 
        # Lock the webpage and print message.
-        &_open_working_notice("$Lang::tr{'ids apply ruleset changes'}");
+       unless ($nolock) {
+               &_open_working_notice("$Lang::tr{'ids apply ruleset changes'}");
+       }
 
         # Check if the files in rulesdir have the correct permissions.
         &IDS::_check_rulesdir_permissions();
@@ -1908,7 +1912,9 @@ sub oinkmaster_web () {
         &_add_to_notice("$Lang::tr{'ids finished'}");
 
        # Close the working notice.
-       &_close_working_notice();
+       unless ($nolock) {
+               &_close_working_notice();
+       }
 }
 
 #