[pkg-opensc-commit] [SCM] OpenCT packaging branch, master, updated. 15cfb721f7620528e878e9eca3b8e80cb70e10b3

Eric Dorland eric at debian.org
Sun May 10 08:30:54 UTC 2009


The following commit has been merged in the master branch:
commit 7a02e792aafd050b413579c8c6106fb5c23b2c77
Merge: 7d92c167700ba63c732c2ff9713c6e527f2f834c f06ebb412b93e014ea93246237b72768b64c76cf
Author: Eric Dorland <eric at debian.org>
Date:   Sun May 10 03:49:48 2009 -0400

    Merge branch 'upstream'
    
    Conflicts:
    	etc/init-script.in

diff --combined etc/init-script.in
index d72e061,1e851aa..0643f57
--- a/etc/init-script.in
+++ b/etc/init-script.in
@@@ -15,6 -15,8 +15,8 @@@
  
  PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
  DAEMON=@sbindir@/openct-control
+ STATUS_DIR="@OPENCT_SOCKET_PATH@"
+ STATUS_FILE="$STATUS_DIR/status"
  NAME=OpenCT
  DESC="smart card terminal framework"
  
@@@ -22,16 -24,16 +24,16 @@@ test -x $DAEMON || exit 
  
  # create the directory for our status and socket files,
  # if it does not exist.
- if ! test -e "@OPENCT_SOCKET_PATH@"
+ if ! test -e "$STATUS_DIR"
  then
- 	mkdir "@OPENCT_SOCKET_PATH@"
+ 	mkdir "$STATUS_DIR"
  
  	# maybe you also want to set owner ship and permissions here.
  	# this example would assign the directory to a group "scard"
  	# and set permissions so only users in that group can access
  	# smart card readers via openct.
- 	chown root:scard "@OPENCT_SOCKET_PATH@"
- 	chmod 0750 "@OPENCT_SOCKET_PATH@"
 -	#chown root:scard "$STATUS_DIR"
 -	#chmod 0750 "$STATUS_DIR"
++	chown root:scard "$STATUS_DIR"
++	chmod 0750 "$STATUS_DIR"
  fi
  
  set -e
@@@ -44,7 -46,10 +46,10 @@@ case "$1" i
  	;;
    stop)
  	echo -n "Stopping $DESC: $NAME "
- 	$DAEMON shutdown
+ 	if [ -f $STATUS_FILE ]; then
+ 		$DAEMON shutdown
+ 		rm -f $STATUS_FILE
+ 	fi
  	echo "."
  	;;
    #reload)
@@@ -67,7 -72,10 +72,10 @@@
  	#	just the same as "restart".
  	#
  	echo -n "Restarting $DESC: $NAME"
- 	$DAEMON shutdown
+ 	if [ -f $STATUS_FILE ]; then
+ 		$DAEMON shutdown
+ 		rm -f $STATUS_FILE
+ 	fi
  	sleep 0.1
  	$DAEMON init
  	echo "."

-- 
OpenCT packaging



More information about the pkg-opensc-commit mailing list