[lintian] 04/04: c/debconf.pm: Use L::Path instead of debfiles
This is an automated email from the git hooks/post-receive script.
nthykier pushed a commit to branch master
in repository lintian.
commit 613daaf01b528f9a5502238db0e699ced6275b02
Author: Niels Thykier <niels@thykier.net>
Date: Sat Sep 27 00:19:39 2014 +0200
c/debconf.pm: Use L::Path instead of debfiles
Signed-off-by: Niels Thykier <niels@thykier.net>
---
checks/debconf.pm | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/checks/debconf.pm b/checks/debconf.pm
index 7cef939..fadb83a 100644
--- a/checks/debconf.pm
+++ b/checks/debconf.pm
@@ -70,7 +70,8 @@ sub run {
push @files, 'templates';
foreach my $file (@files) {
- my $templates_file = $info->debfiles($file);
+ my $dfile = "debian/$file";
+ my $templates_file = $info->index_resolved_path($dfile);
my $binary = $file;
$binary =~ s/\.?templates$//;
# Single binary package (so @files contains "templates" and
@@ -79,11 +80,11 @@ sub run {
$binary = $binaries[0];
}
- if (-f $templates_file) {
+ if ($templates_file and $templates_file->is_open_ok) {
my @templates;
eval {
@templates
- = read_dpkg_control($templates_file,
+ = read_dpkg_control($templates_file->fs_path,
DCTRL_DEBCONF_TEMPLATE);
};
if ($@) {
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/lintian/lintian.git
Reply to: