Fix missing ipsec option value handling

git-svn-id: https://shorewall.svn.sourceforge.net/svnroot/shorewall/trunk@6058 fbd18981-670d-0410-9b5c-8dc0c1a9a2bb
This commit is contained in:
teastep 2007-04-22 14:29:30 +00:00
parent ab17a8ba51
commit abe8ce238d
2 changed files with 4 additions and 2 deletions

View File

@ -77,8 +77,9 @@ sub do_ipsec_options($)
fatal_error "Invalid Option ($e)" unless $fmt;
if ( $fmt eq NOTHING ) {
fatal_error "Option $e does not take a value" if defined $val;
fatal_error "Option \"$e\" does not take a value" if defined $val;
} else {
fatal_error "Missing value for option \"$e\"" unless defined $val;
fatal_error "Invalid value ($val) for option \"$e\"" unless $val =~ /^($fmt)$/;
}

View File

@ -157,8 +157,9 @@ sub parse_zone_option_list($)
fatal_error "Invalid Option ($e)" unless $fmt;
if ( $fmt eq NOTHING ) {
fatal_error "Option $e does not take a value" if defined $val;
fatal_error "Option \"$e\" does not take a value" if defined $val;
} else {
fatal_error "Missing value for option \"$e\"" unless defined $val;
fatal_error "Invalid value ($val) for option \"$e\"" unless $val =~ /^($fmt)$/;
}