From: Sven Eden Date: Thu, 17 May 2018 05:44:41 +0000 (+0200) Subject: migrate_tree.pl : Check target first when creating new files. X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=commitdiff_plain;h=33ca6387b4441cf74fee7e59db7bb36534c07851;p=elogind.git migrate_tree.pl : Check target first when creating new files. --- diff --git a/pwx/last_mutual_commits.csv b/pwx/last_mutual_commits.csv index ad491b883..92788d9f7 100644 --- a/pwx/last_mutual_commits.csv +++ b/pwx/last_mutual_commits.csv @@ -11,4 +11,4 @@ ../systemd-upstream master 265710c20 src-efaa3176a x ../systemd-upstream v234 d6d0473dc src-782c925f7 x ../systemd-upstream v236 83fefc888 src-f78a88bec x -../systemd-upstream v237 a327431bd src-6d8c71eb8 tgt-af44d5dfa +../systemd-upstream v237 7629744a3 src-6d8c71eb8 tgt-b7e108921 diff --git a/pwx/migrate_tree.pl b/pwx/migrate_tree.pl index df81c40f6..c5892c717 100755 --- a/pwx/migrate_tree.pl +++ b/pwx/migrate_tree.pl @@ -868,10 +868,9 @@ sub rework_patch { # The determination what is valid is different for whether this is # the modification of an existing or the creation of a new file if ($isNew) { - defined( $hDirectories{ dirname($src) } ) and $real = $src or - defined( $hDirectories{ dirname($tgt) } ) and $real = $tgt; + defined( $hDirectories{ dirname($tgt) } ) and $real = $tgt or + defined( $hDirectories{ dirname($src) } ) and $real = $src; } else { - # Try the renamed first, then the non-renamed defined( $hFiles{$tgt} ) and $real = $tgt or defined( $hFiles{$src} )