mirror of
https://github.com/munin-monitoring/contrib.git
synced 2025-07-22 02:51:03 +00:00
[mpdstats_] use 'which' for finding 'nc'
This commit is contained in:
parent
d6ea0c926d
commit
380c4a9ea5
1 changed files with 4 additions and 3 deletions
|
@ -69,7 +69,8 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
|||
|
||||
MPDHOST=${mpd_host:-localhost}
|
||||
MPDPORT=${mpd_port:-6600}
|
||||
NCBIN=${netcat:-/bin/nc}
|
||||
NCBIN=${netcat:-$(which nc)}
|
||||
|
||||
|
||||
#
|
||||
# FUNCTIONS
|
||||
|
@ -85,8 +86,8 @@ do_autoconf () {
|
|||
;;
|
||||
esac
|
||||
|
||||
if [ ! -x $NCBIN ] ; then
|
||||
echo "no ($NCBIN: not found or not executable)"
|
||||
if [ -z "$NCBIN" ] ; then
|
||||
echo "no (missing netcat program ('nc'))"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue