Sophie

Sophie

distrib > Mandriva > 2009.1 > x86_64 > by-pkgid > 2cadaa502ea3ef1258708c955dd26c21 > files > 10

bluez-4.33-3.2mdv2009.1.x86_64.rpm

#!/bin/sh
#
# dund:		Bluetooth Dial-Up-Networking Daemon.
#
# chkconfig:	- 26 59
# description:	Bluetooth Dial-Up-Networking Daemon. Provides PPP over RFCOMM
#		services.
#
### BEGIN INIT INFO
# Provides: dund
# Required-Start: $network bluetooth
# Required-Stop: $network bluetooth
# Short-Description: Bluetooth Dial-Up-Networking Daemon
# Description: Bluetooth Dial-Up-Networking Daemon.
#              Provides PPP over RFCOMM services.
### END INIT INFO

# Source function library.
. /etc/rc.d/init.d/functions

. /etc/sysconfig/network

[ ${NETWORKING} = "no" ] && exit 0

[ -r /etc/sysconfig/dund ] || exit 0

. /etc/sysconfig/dund

[ -z "$DUNDARGS" ] && exit 0

start() 
{
        gprintf "Starting dund: "
        daemon /usr/bin/dund $DUNDARGS

	touch /var/lock/subsys/dund
        echo
}

stop() 
{
        gprintf "Shutting down dund: "
	/usr/bin/dund -K
	killproc dund

	rm -f  /var/lock/subsys/dund
        echo
}

[ -f /usr/bin/dund ] || exit 0

# See how we were called.
case "$1" in
  start)
	start
        ;;
  stop)
	stop
        ;;
  restart|reload)
	stop
	start
	;;
  condrestart)
	[ -e /var/lock/subsys/dund ] && (stop; start)
	;;
  status)
  	status dund
	;;
  *)
        gprintf "Usage: %s {start|stop|restart|reload|condrestart|status}\n" "$0"
        exit 1
esac

exit 0