From 02b185571fd07dd736d1c762b6753a00b95d2adb Mon Sep 17 00:00:00 2001 From: Sergio Correia Date: Thu, 8 Nov 2012 11:33:28 -0800 Subject: [PATCH] ArcanistBundle: fix attribution of $old_phid when building binary changes Summary: The variable $old_phid was not being set in a certain situation in buildBinaryChange(), and that was causing the following error, during `arc patch `: "the patch applies to (), which does not match the current contents." and hence it was failing to download/apply the patch. Signed-off-by: Sergio Correia Test Plan: I spotted the problem in a revision where I was renaming some images, which are binary. Reviewers: epriestley, vrana, btrahan Reviewed By: btrahan CC: aran, Korvin Differential Revision: https://secure.phabricator.com/D3925 --- src/parser/ArcanistBundle.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/parser/ArcanistBundle.php b/src/parser/ArcanistBundle.php index 994f15db..f5e4fdf2 100644 --- a/src/parser/ArcanistBundle.php +++ b/src/parser/ArcanistBundle.php @@ -646,7 +646,7 @@ final class ArcanistBundle { $old_phid = null; } else { $old_data = null; - $old_binary->getMetadata('old:binary-phid'); + $old_phid = $old_binary->getMetadata('old:binary-phid'); } } else { $old_data = $change->getOriginalFileData();