mirror of
https://gitlab.com/shorewall/code.git
synced 2024-12-18 20:30:43 +01:00
Save current action chain along with params. Add get_action_chain()
Signed-off-by: Tom Eastep <teastep@shorewall.net>
This commit is contained in:
parent
89ee25dde2
commit
8ab45b4de3
@ -1800,13 +1800,14 @@ sub embedded_perl( $ ) {
|
||||
#
|
||||
# Push/pop action params
|
||||
#
|
||||
sub push_action_params( $ ) {
|
||||
my @params = split /,/, $_[0];
|
||||
sub push_action_params( $$ ) {
|
||||
my @params = split /,/, $_[1];
|
||||
my $oldparams = \@actparms;
|
||||
my $params = @params;
|
||||
|
||||
@actparms = ();
|
||||
|
||||
$actparms[0] = $_[0];
|
||||
@actparms[1..$params] = @params;
|
||||
|
||||
$oldparams;
|
||||
@ -1835,6 +1836,10 @@ sub get_action_params( $ ) {
|
||||
@actparms[1..$num];
|
||||
}
|
||||
|
||||
sub get_actionchain() {
|
||||
$actparms[0];
|
||||
}
|
||||
|
||||
sub set_action_param( $$ ) {
|
||||
my $i = shift;
|
||||
|
||||
|
@ -1465,7 +1465,7 @@ sub process_action( $) {
|
||||
|
||||
push_open $actionfile;
|
||||
|
||||
my $oldparms = push_action_params( $param );
|
||||
my $oldparms = push_action_params( $chainref, $param );
|
||||
|
||||
$active{$wholeaction}++;
|
||||
push @actionstack, $wholeaction;
|
||||
|
Loading…
Reference in New Issue
Block a user