Do not use full path to mountpoint program

It may reside in different places (/bin in Debian, /usr/bin in Fedora).
Use $PATH for this.
This commit is contained in:
Marek Marczykowski-Górecki 2017-07-11 23:56:30 +02:00
parent 78a2699371
commit be395a8ada
No known key found for this signature in database
GPG Key ID: 063938BA42CFA724

View File

@ -88,13 +88,13 @@ umount_kill() {
if ! [ "${kill_only}" ]; then
# Mount point found in mtab
if $(sudo /usr/bin/mountpoint -q "${dir}"); then
if $(sudo mountpoint -q "${dir}"); then
info "umount ${dir}"
sudo umount -n "${dir}" 2> /dev/null || \
sudo umount -n -l "${dir}" 2> /dev/null || \
error "umount ${dir} unsuccessful!"
# Umount entries not found within '/usr/bin/mountpoint'
# Umount entries not found within 'mountpoint'
else
# Look for (deleted) mountpoints
info "not a regular mount point: ${dir}"