#! /bin/sh
#
# loadbrsysctl    (Re)loads the settings in /etc/sysctl.conf
#
# chkconfig: 2345 14 78
# description: (Re)loads the bridge-related settings in /etc/sysctl.conf

. /etc/init.d/functions

start()
{
    grep -q 'bridge' /proc/modules || return
    grep '^net\.bridge\.' /etc/sysctl.conf >/tmp/sysctl.$$
    set -- `wc -l /tmp/sysctl.$$`
    if [ $1 -gt 0 ]; then
	/sbin/sysctl -p /tmp/sysctl.$$ >/dev/null
    fi
    rm -f /tmp/sysctl.$$
}

case "$1" in
    start)
	start
	;;
    stop|status)
	;;
    *)
	echo $"Usage: $0 {start|stop|status}"
	exit 1
	;;
esac
