chiark / gitweb /
sbuild: Check that the binary .changes file doesn't contain a .dsc.
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Fri, 6 Nov 2015 14:32:03 +0000 (14:32 +0000)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Fri, 1 Jul 2016 22:53:44 +0000 (23:53 +0100)
debian/changelog
dgit

index a9c6e9e435457cb443e8a2cbb00daed025674008..44aedd2e16ceeaf010d58220d86ae1d9b1a5780c 100644 (file)
@@ -8,10 +8,12 @@ dgit (1.5~~) unstable; urgency=medium
     to change for the dgit user.
 
   New checks and improved behaviours:
     to change for the dgit user.
 
   New checks and improved behaviours:
-  * In dgit sbuild, check that the set of .changes files found is as we
-    expect, before calling mergechanges, and rename the used-up .changes
-    files to `.inmulti' to avoid accidental use of the wrong one (by
-    software, or by users).
+  * dgit sbuild: check that the set of .changes files found is as we
+    expect, before calling mergechanges.
+  * dgit sbuild: Rename the used-up .changes files to `.inmulti' to
+    avoid accidental  use of the wrong one (by software, or by users).
+  * dgit sbuild: Check that the binary .changes file doesn't contain a
+    .dsc.
 
   Bugfixes:
   * When cleaning up after failed clone, stat the to-be-cleaned-up
 
   Bugfixes:
   * When cleaning up after failed clone, stat the to-be-cleaned-up
diff --git a/dgit b/dgit
index a4dea9b44f6bd67cba42ebe17c361e27e7eb0004..9ac8d54435508550c0b557794f8a32a4d70437d6 100755 (executable)
--- a/dgit
+++ b/dgit
@@ -3154,6 +3154,11 @@ sub cmd_sbuild {
     } @changesfiles;
     fail "wrong number of different changes files (@changesfiles)"
        unless @changesfiles==2;
     } @changesfiles;
     fail "wrong number of different changes files (@changesfiles)"
        unless @changesfiles==2;
+    my $binchanges = parsecontrol($changesfiles[1], "binary changes file");
+    foreach my $l (split /\n/, getfield $binchanges, 'Files') {
+       fail "$l found in binaries changes file $binchanges"
+           if $l =~ m/\.dsc$/;
+    }
     runcmd_ordryrun_local @mergechanges, @changesfiles;
     my $multichanges = "${package}_".(stripepoch $version)."_multi.changes";
     if (act_local()) {
     runcmd_ordryrun_local @mergechanges, @changesfiles;
     my $multichanges = "${package}_".(stripepoch $version)."_multi.changes";
     if (act_local()) {