Avoid extra comparison in reload_command()

Signed-off-by: Tom Eastep <teastep@shorewall.net>
This commit is contained in:
Tom Eastep 2017-09-19 10:49:11 -07:00
parent 721a1e3b33
commit 494ec9c59c
No known key found for this signature in database
GPG Key ID: 96E6B3F2423A4D10

View File

@ -78,11 +78,13 @@ reload_command() {
detect_configuration
define_firewall
status=$?
if [ -n "$SUBSYSLOCK" ]; then
[ $status -eq 0 ] && touch $SUBSYSLOCK || rm -f $SUBSYSLOCK
fi
[ $status -eq 0 ] && progress_message3 "done."
if [ $status -eq 0 ]; then
[ -n "$SUBSYSLOCK" ] && touch $SUBSYSLOCK
progress_message3 "done."
else
[ -n "$SUBSYSLOCK" ] && rm -f $SUBSYSLOCK
fi
}
################################################################################