summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRaphaël Hertzog <hertzog@debian.org>2011-01-03 10:33:28 +0100
committerRaphaël Hertzog <hertzog@debian.org>2011-01-03 10:33:28 +0100
commit930bb774c5aeb2a2a083deb7b92432a7b7ab9a35 (patch)
treef108baad51c8c288e07d1d2796bf14c850ade8f3
parent85fce47c813230e0d9b51826adb479f1f519df6c (diff)
downloaddpkg-930bb774c5aeb2a2a083deb7b92432a7b7ab9a35.tar.gz
Dpkg::Source::Package::V1.pm: correctly detect debian files
The code was erroneously assuming that $newdirectory was always a simple filename, but it can be a complete path.
-rw-r--r--debian/changelog3
-rw-r--r--scripts/Dpkg/Source/Package/V1.pm2
2 files changed, 4 insertions, 1 deletions
diff --git a/debian/changelog b/debian/changelog
index 44de9556f..ceaae4a7a 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -25,6 +25,9 @@ dpkg (1.16.0) UNRELEASED; urgency=low
* Enhance dpkg-shlibdeps to not fail immediatly when a library is not found.
Instead continue and fail after all problems have been reported. Thanks
to Chris Baines <cbaines8@gmail.com> for the patch. Closes: #596841
+ * Fix dpkg-source to not list Debian packaging files as modified
+ upstream files in Format "1.0" when unpacking to a non-standard
+ directory.
[ Updated programs translations ]
* Portuguese (Miguel Figueiredo).
diff --git a/scripts/Dpkg/Source/Package/V1.pm b/scripts/Dpkg/Source/Package/V1.pm
index 2f58103b2..41023cafa 100644
--- a/scripts/Dpkg/Source/Package/V1.pm
+++ b/scripts/Dpkg/Source/Package/V1.pm
@@ -153,7 +153,7 @@ sub do_extract {
my $patch_obj = Dpkg::Source::Patch->new(filename => $patch);
my $analysis = $patch_obj->apply($newdirectory, force_timestamp => 1,
timestamp => time());
- my @files = grep { ! m{^[^/]+/debian/} }
+ my @files = grep { ! m{^\Q$newdirectory\E/debian/} }
sort keys %{$analysis->{'filepatched'}};
info(_g("upstream files that have been modified: %s"),
"\n " . join("\n ", @files)) if scalar @files;