chiark / gitweb /
dopush: Break out $changes variable
[dgit.git] / dgit
diff --git a/dgit b/dgit
index e261a2982f046dedbf6692b2d1a0b3b47b568e3e..60ea9194054a082193d490c85d874cc676a63ee6 100755 (executable)
--- a/dgit
+++ b/dgit
@@ -3236,11 +3236,12 @@ END
     my $dgithead = $actualhead;
     my $maintviewhead = undef;
 
+    my $upstreamversion = $clogp->{Version};
+    $upstreamversion =~ s/-[^-]*$//;
+
     if (madformat_wantfixup($format)) {
        # user might have not used dgit build, so maybe do this now:
        if (quiltmode_splitbrain()) {
-           my $upstreamversion = $clogp->{Version};
-           $upstreamversion =~ s/-[^-]*$//;
            changedir $ud;
            quilt_make_fake_dsc($upstreamversion);
            my $cachekey;
@@ -3324,7 +3325,8 @@ END
 
     # Check that changes and .dsc agree enough
     $changesfile =~ m{[^/]*$};
-    files_compare_inputs($dsc, parsecontrol($changesfile,$&))
+    my $changes = parsecontrol($changesfile,$&);
+    files_compare_inputs($dsc, $changes)
        unless forceing [qw(dsc-changes-mismatch)];
 
     # Checks complete, we're going to try and go ahead: