From 5ef9b378f5c15d1c90d443ba513703471ffd0649 Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Mon, 7 Feb 2011 09:34:24 +0000 Subject: bitbake/fetch2/git.py: Ensure that forcefetch operates in the correct directory for calling _contains_ref() (From Poky rev: 330886826770ff6ec1449dc375cb4c3604b2736b) Signed-off-by: Richard Purdie --- lib/bb/fetch2/git.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/bb/fetch2/git.py b/lib/bb/fetch2/git.py index 8386ecca0..a78e4519e 100644 --- a/lib/bb/fetch2/git.py +++ b/lib/bb/fetch2/git.py @@ -81,6 +81,9 @@ class Git(FetchMethod): return ud.clonedir def forcefetch(self, url, ud, d): + if not os.path.exists(ud.clonedir): + return True + os.chdir(ud.clonedir) for name in ud.names: if not self._contains_ref(ud.revisions[name], d): return True -- cgit 1.2.3-korg