vzctl set --ipdel all: do not run *add_ip.sh script

When "vzctl set $CTID --ipdel all" is executed, vzctl runs
*del_ip.sh script and then *add_ip.sh script. There is no need
to run the second one if list of IPs to add is empty.

This should prevent (re)creating empty configuration for venet0
inside a container.

While at it, document the complicated "if" statement, so now it
becomes more-or-less comprehensive.

Signed-off-by: Kir Kolyshkin <kir@openvz.org>
1 file changed