--- nagios-plugins-1.4.13/plugins-scripts/subst.in.orig 2009-03-31 13:59:58.000000000 +1100 +++ nagios-plugins-1.4.13/plugins-scripts/subst.in 2009-03-31 14:01:30.000000000 +1100 @@ -62,11 +62,14 @@ # subst will replace the fully qualified command with whatever is # returned from the which subroutine # -/^[^#]/ && /(\/.*)?\/(bin|sbin|lib|libexec)\// { - match($0,/(\/.*)?\/(bin|sbin|lib|libexec)\/[-_a-zA-Z0-9]+/); - c=substr($0,RSTART,RLENGTH); - sub(c,which(c,path)); -} +# REMOVED: had collateral dammage of also replacing library paths: +# use lib "/usr/lib/nagios/plugins" ==> use lib "nagios/plugins", +# this is wrong, and provides no real benefit for executables +#/^[^#]/ && /(\/.*)?\/(bin|sbin|lib|libexec)\// { +# match($0,/(\/.*)?\/(bin|sbin|lib|libexec)\/[-_a-zA-Z0-9]+/); +# c=substr($0,RSTART,RLENGTH); +# sub(c,which(c,path)); +#} { print;