1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
|
From: Faidon Liambotis <paravoid@debian.org>
Date: Mon, 24 Feb 2020 21:59:33 +0200
Subject: Fix (deferred) functions within target arguments
Since deferred functions were introduced (commits fe99bc2, 31bb5d3
etc.), passing functions like @ipfilter to target arguments (such SNAT's
to-source) was broken, resulting into broken output.
Abstract the realization of deferred functions into a separate
subroutine, and call it also from parse_keyword().
Thanks to Endre Szabo for reporting this issue. Fixes #63.
---
src/ferm | 2 --
1 file changed, 2 deletions(-)
diff --git a/src/ferm b/src/ferm
index 47fed83..dc29ef0 100755
--- a/src/ferm
+++ b/src/ferm
@@ -1750,10 +1750,8 @@ sub realize_deferred {
if (ref $inside_value and ref $inside_value eq 'deferred') {
my @args = @$inside_value;
my $function = shift @args;
-
# realize nested deferred calls recursively
@args = realize_deferred($domain, @args);
-
push @values, &$function($domain, @args);
} else {
push @values, $inside_value;
|