From 87b6f7d27ace9d6465414c28bbba003f368a49dd Mon Sep 17 00:00:00 2001 From: Bernhard Reutner-Fischer Date: Wed, 17 Nov 2010 14:44:40 +0100 Subject: fetch: add common helper _strip_leading_slashes() Several fetcher need a way to strip leading slashes off a local path. This helper-function consolidates all such occurances. (Bitbake rev: 823a02185ed109054c6c1ae366221aaed0353f24) Signed-off-by: Bernhard Reutner-Fischer Signed-off-by: Richard Purdie --- bitbake/lib/bb/fetch/perforce.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'bitbake/lib/bb/fetch/perforce.py') diff --git a/bitbake/lib/bb/fetch/perforce.py b/bitbake/lib/bb/fetch/perforce.py index 6f68d8561..bdd23deef 100644 --- a/bitbake/lib/bb/fetch/perforce.py +++ b/bitbake/lib/bb/fetch/perforce.py @@ -113,8 +113,7 @@ class Perforce(Fetch): if which != -1: base = path[:which] - if base[0] == "/": - base = base[1:] + base = self._strip_leading_slashes(base) cset = Perforce.getcset(d, path, host, user, pswd, parm) -- cgit v1.2.3