From f80334d8aa680c249d84df9109ceca9e7a479cdd Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Fri, 28 Mar 2014 11:06:18 +0000 Subject: bitbake: cooker: Only change self.data if it exists With the change to more optimal default featureset behaviour, a race was exposed by hob where the code may try and change self.data before it exists. This change avoids that. When the datastore is created, the cooker configuration is used so data tracking is correctly handled regardless. (Bitbake rev: 9d8f7efbc39d64124936ccaeb3c47a112e595d78) Signed-off-by: Richard Purdie --- bitbake/lib/bb/cooker.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'bitbake/lib/bb/cooker.py') diff --git a/bitbake/lib/bb/cooker.py b/bitbake/lib/bb/cooker.py index e81d887268..5d3ac607f5 100644 --- a/bitbake/lib/bb/cooker.py +++ b/bitbake/lib/bb/cooker.py @@ -207,11 +207,13 @@ class BBCooker: def enableDataTracking(self): self.configuration.tracking = True - self.data.enableTracking() + if hasattr(self, "data"): + self.data.enableTracking() def disableDataTracking(self): self.configuration.tracking = False - self.data.disableTracking() + if hasattr(self, "data"): + self.data.disableTracking() def modifyConfigurationVar(self, var, val, default_file, op): if op == "append": -- cgit v1.2.3-54-g00ecf