aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPhil Sutter <psutter@redhat.com>2018-06-12 13:54:15 +0200
committerDee'Kej <deekej@linuxmail.org>2018-06-14 16:27:36 +0200
commit88b3ac3840cc993901f971a2a99046881d9e46c4 (patch)
tree15cd8fd13ac092d0712b63d93d622a93caa840a9
parentbf40c2768d6b6614cc0f1b4fb68ca011489e89d3 (diff)
downloadinitscripts-88b3ac3840cc993901f971a2a99046881d9e46c4.tar
initscripts-88b3ac3840cc993901f971a2a99046881d9e46c4.tar.gz
initscripts-88b3ac3840cc993901f971a2a99046881d9e46c4.tar.bz2
initscripts-88b3ac3840cc993901f971a2a99046881d9e46c4.tar.xz
initscripts-88b3ac3840cc993901f971a2a99046881d9e46c4.zip
network-scripts: Add previously dropped error checking
When converting from brctl to ip-link, the call to exit in case bridge adding failed was dropped by accident.
-rwxr-xr-xnetwork-scripts/ifup-eth4
1 files changed, 2 insertions, 2 deletions
diff --git a/network-scripts/ifup-eth b/network-scripts/ifup-eth
index bbb17790..b55db79e 100755
--- a/network-scripts/ifup-eth
+++ b/network-scripts/ifup-eth
@@ -58,9 +58,9 @@ if [ "${TYPE}" = "Bridge" ]; then
[ -n "${AGEING}" ] && bridge_opts+="ageing_time ${AGEING} "
if [ ! -d /sys/class/net/${DEVICE}/bridge ]; then
- ip link add ${DEVICE} type bridge $bridge_opts
+ ip link add ${DEVICE} type bridge $bridge_opts || exit 1
elif [ -n "${OPTS}" ]; then
- ip link set ${DEVICE} type bridge $bridge_opts
+ ip link set ${DEVICE} type bridge $bridge_opts || exit 1
fi
unset bridge_opts