Index: head/net/socat/files/socat.in =================================================================== --- head/net/socat/files/socat.in (revision 342583) +++ head/net/socat/files/socat.in (revision 342584) @@ -1,39 +1,39 @@ #!/bin/sh # # Author: Emanuel Haupt # # $FreeBSD$ # # PROVIDE: socat # REQUIRE: LOGIN # KEYWORD: shutdown # Add the following lines to /etc/rc.conf to enable socat: # socat_enable="YES" # socat_flags="" . /etc/rc.subr name="socat" rcvar=socat_enable load_rc_config $name : ${socat_enable="NO"} start_precmd="socat_prestart" pidfile=/var/run/socat.pid +procname="%%PREFIX%%/bin/socat" command=/usr/sbin/daemon -command_args=" -f -p ${pidfile} /usr/local/bin/socat ${socat_flags}" -procname=/usr/local/bin/socat +command_args=" -f -p ${pidfile} ${procname} ${socat_flags}" socat_prestart() { # socat_flags gets applied too early if we don't do this. # I didn't want to force people to update their rc.conf files # and change the socat_flags to something else. rc_flags="" } run_rc_command "$1"