Browse Source

maintainer scripts: use invoke-rc.d instead of directly invoking init script

Addressing lintian errors:

| E: ngcp-mediaproxy-ng-kernel-dkms: maintainer-script-calls-init-script-directly postinst:22
| E: ngcp-mediaproxy-ng-kernel-dkms: maintainer-script-calls-init-script-directly prerm:12

From: Michael Prokop <mprokop@sipwise.com>
git.mgm/mediaproxy-ng/2.0
Michael Prokop 14 years ago
parent
commit
78220ab3ea
2 changed files with 4 additions and 2 deletions
  1. +1
    -1
      debian/ngcp-mediaproxy-ng-kernel-dkms.postinst
  2. +3
    -1
      debian/ngcp-mediaproxy-ng-kernel-dkms.prerm

+ 1
- 1
debian/ngcp-mediaproxy-ng-kernel-dkms.postinst View File

@ -19,7 +19,7 @@ if [ "$1" = 'configure' ] ; then
# try to start the daemon
if [ -x /etc/init.d/ngcp-mediaproxy-ng-daemon ] ; then
/etc/init.d/ngcp-mediaproxy-ng-daemon start || true
invoke-rc.d ngcp-mediaproxy-ng-daemon start || true
fi
fi


+ 3
- 1
debian/ngcp-mediaproxy-ng-kernel-dkms.prerm View File

@ -9,7 +9,9 @@ version=`dpkg-query -W -f='${Version}' "$package" \
|rev|cut -d- -f2-|rev|cut -d':' -f2|tr -d "\n"`
# make sure it's not running
/etc/init.d/ngcp-mediaproxy-ng-daemon stop || true
if [ -x /etc/init.d/ngcp-mediaproxy-ng-daemon ] ; then
invoke-rc.d ngcp-mediaproxy-ng-daemon stop || true
fi
dkms remove -m "$name" -v "$version" --all || true


Loading…
Cancel
Save