summaryrefslogtreecommitdiff
path: root/dh_installinit
diff options
context:
space:
mode:
authorJoey Hess <joey@gnu.kitenet.net>2009-11-30 14:21:02 -0500
committerJoey Hess <joey@gnu.kitenet.net>2009-11-30 14:21:02 -0500
commit66c3c074c2c663fd38d88e4bac770ac7c824cc10 (patch)
treee4d1ee7a27d231b409d51fe2d0a8a80ea65a0ffc /dh_installinit
parent9942b80e9985e36983a692316879bace98da8b39 (diff)
dh_installinit: Fix installation of defaults file when an upstart job is installed. Closes: #558782
Diffstat (limited to 'dh_installinit')
-rwxr-xr-xdh_installinit7
1 files changed, 3 insertions, 4 deletions
diff --git a/dh_installinit b/dh_installinit
index 7b1d2e2..c053132 100755
--- a/dh_installinit
+++ b/dh_installinit
@@ -177,7 +177,7 @@ foreach my $package (@{$dh{DOPACKAGES}}) {
}
my $job=pkgfile($package,"upstart");
- my ($init,$default) = ('','');
+ my $init='';
if ($job ne '' || ($dh{ONLYSCRIPTS} && -e "$tmp/etc/init/$jobfile.conf")) {
if (! $dh{ONLYSCRIPTS}) {
@@ -200,9 +200,9 @@ foreach my $package (@{$dh{DOPACKAGES}}) {
else {
$init=pkgfile($package,$script) || pkgfile($package,"init") ||
pkgfile($package,"init.d");
- $default=pkgfile($package,'default');
}
+ my $default=pkgfile($package,'default');
if ($default ne '' && ! $dh{ONLYSCRIPTS}) {
if (! -d "$tmp/etc/default") {
doit("install","-d","$tmp/etc/default");
@@ -218,8 +218,7 @@ foreach my $package (@{$dh{DOPACKAGES}}) {
doit("install","-p","-m755",$init,"$tmp/etc/init.d/$script");
}
- if ($job ne '' || $init ne '' || $dh{ONLYSCRIPTS})
- {
+ if ($job ne '' || $init ne '' || $dh{ONLYSCRIPTS}) {
if (-e "$tmp/etc/init/$jobfile.conf") {
$script=$jobfile;
}