chiark / gitweb /
dsc import: Reorganise to make room for resolve_dsc_field_commit
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Sun, 8 Jan 2017 03:24:19 +0000 (03:24 +0000)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Sun, 8 Jan 2017 23:43:36 +0000 (23:43 +0000)
No functional change

Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
dgit

diff --git a/dgit b/dgit
index 775e03ccd6ac01ee64232a820dee6a343b52ed14..af9b182fcf5e7952479d8778f517f6da53e4f272 100755 (executable)
--- a/dgit
+++ b/dgit
@@ -6023,10 +6023,11 @@ sub cmd_import_dsc {
     parse_dscdata();
 
     $package = getfield $dsc, 'Source';
-    parse_dsc_field($dsc, "Dgit metadata in .dsc");
 
-    if (defined $dsc_hash
-       && !forceing [qw(import-dsc-with-dgit-field)]) {
+    parse_dsc_field($dsc, "Dgit metadata in .dsc")
+       unless forceing [qw(import-dsc-with-dgit-field)];
+
+    if (defined $dsc_hash) {
        progress "dgit: import-dsc of .dsc with Dgit field, using git hash";
        my @cmd = (qw(sh -ec),
                   "echo $dsc_hash | git cat-file --batch-check");