rc.subr (164629) | rc.subr (164640) |
---|---|
1# $NetBSD: rc.subr,v 1.66 2006/04/01 10:05:50 he Exp $ 2# $FreeBSD: head/etc/rc.subr 164629 2006-11-26 19:03:19Z flz $ | 1# $NetBSD: rc.subr,v 1.67 2006/10/07 11:25:15 elad Exp $ 2# $FreeBSD: head/etc/rc.subr 164640 2006-11-26 22:02:09Z flz $ |
3# 4# Copyright (c) 1997-2004 The NetBSD Foundation, Inc. 5# All rights reserved. 6# 7# This code is derived from software contributed to The NetBSD Foundation 8# by Luke Mewburn. 9# 10# Redistribution and use in source and binary forms, with or without --- 245 unchanged lines hidden (view full) --- 256 err 3 'USAGE: _find_processes procname interpreter psargs' 257 fi 258 _procname=$1 259 _interpreter=$2 260 _psargs=$3 261 262 _pref= 263 if [ $_interpreter != "." ]; then # an interpreted script | 3# 4# Copyright (c) 1997-2004 The NetBSD Foundation, Inc. 5# All rights reserved. 6# 7# This code is derived from software contributed to The NetBSD Foundation 8# by Luke Mewburn. 9# 10# Redistribution and use in source and binary forms, with or without --- 245 unchanged lines hidden (view full) --- 256 err 3 'USAGE: _find_processes procname interpreter psargs' 257 fi 258 _procname=$1 259 _interpreter=$2 260 _psargs=$3 261 262 _pref= 263 if [ $_interpreter != "." ]; then # an interpreted script |
264 read _interp < $_procname # read interpreter name | 264 read _interp < ${_chroot:-}/$_procname # read interpreter name |
265 _interp=${_interp#\#!} # strip #! 266 set -- $_interp 267 if [ $_interpreter != $1 ]; then 268 warn "\$command_interpreter $_interpreter != $1" 269 fi 270 _interp="$* $_procname" # cleanup spaces, add _procname 271 _interpbn=${1##*/} 272 _fp_args='_argv' --- 1219 unchanged lines hidden --- | 265 _interp=${_interp#\#!} # strip #! 266 set -- $_interp 267 if [ $_interpreter != $1 ]; then 268 warn "\$command_interpreter $_interpreter != $1" 269 fi 270 _interp="$* $_procname" # cleanup spaces, add _procname 271 _interpbn=${1##*/} 272 _fp_args='_argv' --- 1219 unchanged lines hidden --- |