#!/bin/bash
#
. /etc/rc.d/init.d/functions

case "$1" in
  start)
        echo "Mounting smb file system."
        if [ -s /etc/opt/nec/wbmc/wbmc_smbmnt ]; then
                /etc/opt/nec/wbmc/wbmc_smbmnt
        fi
        touch /var/lock/subsys/wbmcsmb
        ;;
  stop)
        echo "Unmounting smb file system."
        if [ -s /etc/opt/nec/wbmc/wbmc_smbunmnt ]; then
                /etc/opt/nec/wbmc/wbmc_smbunmnt
        fi
        rm -f /var/lock/subsys/wbmcsmb
        ;;
  restart)
        $0 stop
        $0 start
        ;;
  status)
        # status wbmcsmb
        /bin/mount -t smbfs
        ;;
  *)
        echo "Usage: wbmcsmb {start|stop|restart|status}"
        exit 1
esac

exit 0

