+2007-05-15 Guillem Jover <guillem@debian.org>
+
+ * scripts/update-alternatives.pl: Call fill_missing_slavepaths at the
+ end of the 'install' conditional.
+ (fill_missing_slavepaths): New function.
+
2007-05-14 Guillem Jover <guillem@debian.org>
* scripts/dpkg-divert.pl ($divertto, $package): Initialize to undef
* Fix perl warnings:
- In dpkg-genchanges when called with -S. Closes: #423193
- In architecture comparison operations. Closes: #423452
+ - Fill slavepaths undefined entries with an empty string to guarantee
+ they are always defined. Closes: #423140, #423451, #423544, #423555
* Include the new split man pages deb-substvars.5, deb-override.5 and
deb-shlibs.5 in dpkg-dev.
* Fix deb-substvars.5 section to match reality.
}
}
+sub fill_missing_slavepaths()
+{
+ for (my $j = 0; $j <= $#slavenames; $j++) {
+ for (my $i = 0; $i <= $#versions; $i++) {
+ $slavepath{$i,$j} = '' if !defined $slavepath{$i,$j};
+ }
+ }
+}
+
sub find_best_version
{
$best = '';
for (my $j = 0; $j <= $#slavenames; $j++) {
$slavepath{$i,$j}= $aslavepath{$slavenames[$j]};
}
+
+ fill_missing_slavepaths();
}
if ($action eq 'remove') {