forked from extern/shorewall_code
Correct iptablesbug() to handle -g
Signed-off-by: Tom Eastep <teastep@shorewall.net>
This commit is contained in:
parent
4c2df6fea7
commit
e4e11ad5f1
@ -82,11 +82,11 @@ iptablesbug()
|
|||||||
if [ $g_family -eq 4 ]; then
|
if [ $g_family -eq 4 ]; then
|
||||||
if qt mywhich awk ; then
|
if qt mywhich awk ; then
|
||||||
awk 'BEGIN { sline=""; };\
|
awk 'BEGIN { sline=""; };\
|
||||||
/^-j/ { print sline $0; next };\
|
/^-[jg]/ { print sline $0; next };\
|
||||||
/-m policy.*-j/ { print $0; next };\
|
/-m policy.*-[jg] / { print $0; next };\
|
||||||
/-m policy/ { sline=$0; next };\
|
/-m policy/ { sline=$0; next };\
|
||||||
/--mask ff/ { sub( /--mask ff/, "--mask 0xff" ) };\
|
/--mask ff/ { sub( /--mask ff/, "--mask 0xff" ) };\
|
||||||
{ print ; sline="" }'
|
{ print ; sline="" }'
|
||||||
else
|
else
|
||||||
echo " WARNING: You don't have 'awk' on this system so the output of the save command may be unusable" >&2
|
echo " WARNING: You don't have 'awk' on this system so the output of the save command may be unusable" >&2
|
||||||
cat
|
cat
|
||||||
|
Loading…
Reference in New Issue
Block a user