1
0
mirror of synced 2026-01-13 15:17:30 +00:00

Handle potentially empty gateway setting properly

… in hooks/common/40-setup-networking-deb

Thanks Simone Caruso!
This commit is contained in:
Axel Beckert 2013-09-24 23:11:05 +02:00
parent 571f540992
commit 205bf96f0a
2 changed files with 11 additions and 1 deletions

2
debian/changelog vendored
View File

@ -16,6 +16,8 @@ xen-tools (4.4~dev-1) UNRELEASED; urgency=low
xen-create-image, neither xt-create-xen-config nor xm support it.
* Refactoring: Replace all occurrences of "! -z" by "-n" in hooks and
bash completion.
* Handle potentially empty gateway setting properly in
hooks/common/40-setup-networking-deb. Thanks Simone Caruso!
-- Axel Beckert <abe@debian.org> Fri, 23 Aug 2013 21:13:07 +0200

View File

@ -85,6 +85,14 @@ setupStaticNetworking ()
bcast=" broadcast ${broadcast}"
fi
#
# gateway address?
#
gateway='';
if [ -n "${gateway}" ]; then
gateway=" gateway ${gateway}"
fi
#
# We have a static IP address
#
@ -100,7 +108,7 @@ iface lo inet loopback
auto eth0
iface eth0 inet static
address ${ip1}
gateway ${gateway}
${gateway}
netmask ${netmask}
${bcast}
${point}