Another tiny performance enhancement

This commit is contained in:
Tom Eastep 2009-08-17 12:58:50 -07:00
parent 49a2ff05ce
commit 787a1867a0
3 changed files with 5 additions and 4 deletions

View File

@ -38,7 +38,7 @@ our @EXPORT_OK = qw( );
our $VERSION = '4.3_7'; our $VERSION = '4.3_7';
# #
# Called by the compiler # Called by the compiler to [re-]initialize this module's state
# #
sub initialize() { sub initialize() {
our $jumpchainref; our $jumpchainref;

View File

@ -414,10 +414,11 @@ sub decr_cmd_level( $ ) {
# #
sub add_commands ( $$;@ ) { sub add_commands ( $$;@ ) {
my $chainref = shift @_; my $chainref = shift @_;
my $indentation = ' ' x $chainref->{cmdlevel};
for ( @_ ) { for ( @_ ) {
push @{$chainref->{rules}}, join ('', ' ' x $chainref->{cmdlevel} , $_ ); push @{$chainref->{rules}}, join ('', $indentation , $_ );
} }
$chainref->{referenced} = 1; $chainref->{referenced} = 1;

View File

@ -571,7 +571,7 @@ sub compiler {
} }
# #
# Now that we know the address family that we are dealing with (IPv4/IPv6), we can initialize the other modules' globals # Now that we know the address family (IPv4/IPv6), we can initialize the other modules' globals
# #
initialize_package_globals; initialize_package_globals;