]> code.ossystems Code Review - openembedded-core.git/commitdiff
fetch: Check for existence of tar file along with md5 signature
authorKhem Raj <raj.khem@gmail.com>
Wed, 5 May 2010 05:56:49 +0000 (22:56 -0700)
committerRichard Purdie <rpurdie@linux.intel.com>
Fri, 2 Jul 2010 14:41:34 +0000 (15:41 +0100)
(Bitbake rev: a5b1c0605328660de15bb8127b6f7d798c664d32)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Chris Larson <chris_larson@mentor.com>
Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
bitbake/lib/bb/fetch/__init__.py

index f52b0acfc799963ff4dbc570532aefff493313d6..ef33e6da41b605af17c11ba0e3bdc951257ee2a4 100644 (file)
@@ -232,7 +232,7 @@ def go(d, urls = None):
         ud = urldata[u]
         m = ud.method
         if ud.localfile:
-            if not m.forcefetch(u, ud, d) and os.path.exists(ud.md5):
+            if not m.forcefetch(u, ud, d) and os.path.exists(ud.md5) and os.path.exists(ud.localfile):
                 # File already present along with md5 stamp file
                 # Touch md5 file to show activity
                 try:
@@ -242,7 +242,7 @@ def go(d, urls = None):
                     pass
                 continue
             lf = bb.utils.lockfile(ud.lockfile)
-            if not m.forcefetch(u, ud, d) and os.path.exists(ud.md5):
+            if not m.forcefetch(u, ud, d) and os.path.exists(ud.md5) and os.path.exists(ud.localfile):
                 # If someone else fetched this before we got the lock,
                 # notice and don't try again
                 try: