#!/bin/sh
wnnserver=/usr/local/bin/cWnn4/cserver
case "$1" in
start)
  if [ -x /usr/local/bin/cWnn4/cserver ]; then
    /usr/local/bin/cWnn4/cwnnstat -L zh_CN localhost > /dev/null 2>&1
    if [ $? = 255 ]; then
      rm -f  /tmp/cd_sockV4
      echo -n ' cWnn'
      /usr/local/bin/cWnn4/cserver > /dev/null
    fi
  fi
  ;;
stop)
  /usr/local/bin/cWnn4/cwnnkill -L zh_CN localhost
  ;;
*)
  echo "Usage: `basename $0` {start|stop}" >&2
  exit 64
  ;;
esac

exit 0

