summaryrefslogtreecommitdiffstats
path: root/lib/bb/persist_data.py
diff options
context:
space:
mode:
authorChris Larson <chris_larson@mentor.com>2011-02-08 10:41:58 -0700
committerChris Larson <chris_larson@mentor.com>2011-02-08 10:41:58 -0700
commitd93fcbd64ab5d806288424170f55323b4297e7d6 (patch)
tree86848b2d72286d88fa93dce74df6fd3bea02bdfa /lib/bb/persist_data.py
parent16e296b918e3a897153e2c93133bd9dbb6ae17c4 (diff)
downloadbitbake-contrib-d93fcbd64ab5d806288424170f55323b4297e7d6.tar.gz
persist_data: loop on database lock for table creation
Signed-off-by: Chris Larson <chris_larson@mentor.com>
Diffstat (limited to 'lib/bb/persist_data.py')
-rw-r--r--lib/bb/persist_data.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/bb/persist_data.py b/lib/bb/persist_data.py
index b8c239294..5fe032238 100644
--- a/lib/bb/persist_data.py
+++ b/lib/bb/persist_data.py
@@ -47,8 +47,8 @@ class SQLTable(collections.MutableMapping):
self.cursor = cursor
self.table = table
- cursor.execute("CREATE TABLE IF NOT EXISTS %s(key TEXT, value TEXT);"
- % table)
+ self._execute("CREATE TABLE IF NOT EXISTS %s(key TEXT, value TEXT);"
+ % table)
def _execute(self, *query):
"""Execute a query, waiting to acquire a lock if necessary"""