From: Ben Pfaff Date: Fri, 3 Feb 2012 17:33:47 +0000 (-0800) Subject: rhel: Simplify ifup-ovs script use of "case". X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=e31f6c5d1c26e9b86adb6449226b4f08f2c8d7a5;p=openvswitch rhel: Simplify ifup-ovs script use of "case". Suggested-by: "Alexey I. Froloff" Signed-off-by: Ben Pfaff --- diff --git a/rhel/etc_sysconfig_network-scripts_ifup-ovs b/rhel/etc_sysconfig_network-scripts_ifup-ovs index 18cebc4d..4773ee42 100755 --- a/rhel/etc_sysconfig_network-scripts_ifup-ovs +++ b/rhel/etc_sysconfig_network-scripts_ifup-ovs @@ -37,11 +37,8 @@ case "$TYPE" in OVSBridge) ovs-vsctl -- --may-exist add-br "$DEVICE" $OVS_OPTIONS ${OVS_EXTRA+-- $OVS_EXTRA} if [ "${OVSBOOTPROTO}" = "dhcp" ] && [ -n "${OVSINTF}" ]; then - case ${OVSDHCPINTERFACES} in - ${OVSINTF#ifcfg-} | \ - "${OVSINTF#ifcfg-},"* | \ - *",${OVSINTF#ifcfg-}" | \ - *",${OVSINTF#ifcfg-},"*) + case ,${OVSDHCPINTERFACES}, in + *,${OVSINTF#ifcfg-},*) BOOTPROTO=dhcp ${OTHERSCRIPT} ${CONFIG} ;; esac