[oe-commits] [bitbake] 03/05: fetch2/__init__.py: Error if lockfile path invalid

git at git.openembedded.org git at git.openembedded.org
Fri Feb 26 23:45:34 UTC 2016


rpurdie pushed a commit to branch master-next
in repository bitbake.

commit b44c6d26629afbc3b4f5fa4e02702dc778b18631
Author: Richard Purdie <richard.purdie at linuxfoundation.org>
AuthorDate: Fri Feb 26 17:50:37 2016 +0000

    fetch2/__init__.py: Error if lockfile path invalid
    
    Rather than create ".lock" and ".done" files with no name, error,
    forcing us to fix the cases where this is a problem.
    
    Signed-off-by: Richard Purdie <richard.purdie at linuxfoundation.org>
---
 lib/bb/fetch2/__init__.py | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/lib/bb/fetch2/__init__.py b/lib/bb/fetch2/__init__.py
index e7e0007..8e99e91 100644
--- a/lib/bb/fetch2/__init__.py
+++ b/lib/bb/fetch2/__init__.py
@@ -1188,8 +1188,11 @@ class FetchData(object):
             basepath = self.localpath
         elif self.localpath:
             basepath = dldir + os.sep + os.path.basename(self.localpath)
-        else:
+        elif self.basepath or self.basename:
             basepath = dldir + os.sep + (self.basepath or self.basename)
+        else:
+             bb.fatal("Can't determine lock path for url %s" % url)
+
         self.donestamp = basepath + '.done'
         self.lockfile = basepath + '.lock'
 

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the Openembedded-commits mailing list