From b98fdc1545669268d4fb4a241a9a8faba6b62f76 Mon Sep 17 00:00:00 2001 From: hrs Date: Mon, 27 Aug 2007 20:07:08 +0000 Subject: Update to 8.1.16. Changes include: - added 'replstring' substitution option - inspired by conversation with Owen DeLong - added '^Ecn' option for writing a note to the logfile - patch by Bryan Schmersal - fixed leaking file descriptors when 'host' and 'uds' consoles fail to connect - based on patch by Michael Heironimus Also, the rc.d script now supports "reload", "reconnect", and "reinit" keywords (they are to send HUP/USR1/USR2 respectively). Approved by: kuriyama (maintainer) --- comms/conserver-com/Makefile | 2 +- comms/conserver-com/distinfo | 6 ++--- comms/conserver-com/files/conserver.sh.in | 37 +++++++++++++++++++++++++++++-- 3 files changed, 39 insertions(+), 6 deletions(-) diff --git a/comms/conserver-com/Makefile b/comms/conserver-com/Makefile index 56353ba901f9..e31ee309a72f 100644 --- a/comms/conserver-com/Makefile +++ b/comms/conserver-com/Makefile @@ -6,7 +6,7 @@ # PORTNAME= conserver -PORTVERSION= 8.1.15 +PORTVERSION= 8.1.16 CATEGORIES= comms MASTER_SITES= http://www.conserver.com/ \ ftp://ftp.conserver.com/conserver/ diff --git a/comms/conserver-com/distinfo b/comms/conserver-com/distinfo index 874cf8abb74a..34db7809de5b 100644 --- a/comms/conserver-com/distinfo +++ b/comms/conserver-com/distinfo @@ -1,3 +1,3 @@ -MD5 (conserver-8.1.15.tar.gz) = fba8bf42d32cf2119cd0f49b2043681c -SHA256 (conserver-8.1.15.tar.gz) = 66b632664177c8a95161ece76617208c92688973fd0c3db554ccac08522bc409 -SIZE (conserver-8.1.15.tar.gz) = 310032 +MD5 (conserver-8.1.16.tar.gz) = 2364ba56f5201b07646bdfaefedd330b +SHA256 (conserver-8.1.16.tar.gz) = 43dc9d81bc23d76a0ec01acd1f54f5c276b715feeb8f52bb33b5c81f325a46d8 +SIZE (conserver-8.1.16.tar.gz) = 311373 diff --git a/comms/conserver-com/files/conserver.sh.in b/comms/conserver-com/files/conserver.sh.in index 4b1b79c999c9..89092fdd830c 100644 --- a/comms/conserver-com/files/conserver.sh.in +++ b/comms/conserver-com/files/conserver.sh.in @@ -13,11 +13,44 @@ name="conserver" rcvar=`set_rcvar` command=%%PREFIX%%/sbin/${name} -pidfile=/var/run/conserver.pid -required_files=%%PREFIX%%/etc/conserver.cf +pidfile=/var/run/${name}.pid +required_files=%%PREFIX%%/etc/${name}.cf +extra_commands="reload reconnect reinit" +reconnect_cmd="reconnect_cmd" +reinit_cmd="reinit_cmd" load_rc_config $name : ${conserver_enable="NO"} : ${conserver_flags="-d"} +kill_cmd() +{ + _msg=$1 + _sig=$2 + + if [ -z "$rc_pid" ]; then + if [ -n "$pidfile" ]; then + echo 1>&2 \ + "${name} not running? (check $pidfile)." + else + echo 1>&2 "${name} not running?" + fi + return 1 + fi + echo "$_msg" + kill -${_sig:-HUP} $rc_pid + _return=$? + [ $_return -ne 0 ] && [ -z "$rc_force" ] && return 1 +} + +reconnect_cmd() +{ + kill_cmd "Try to reconnect all downed consoles." USR1 +} + +reinit_cmd() +{ + kill_cmd "Try to close and reopen all log files and downed connections." USR2 +} + run_rc_command "$1" -- cgit