]> git.proxmox.com Git - mirror_edk2.git/blobdiff - BaseTools/Source/Python/UPT/Core/IpiDb.py
BaseTools/UPT:merge UPT Tool use Python2 and Python3
[mirror_edk2.git] / BaseTools / Source / Python / UPT / Core / IpiDb.py
index a781d358c86c0d742978ef6ee92366c0e791bc51..48defeac7ee71448bfe2a1d307aee0f28c6a7a74 100644 (file)
@@ -44,7 +44,7 @@ class IpiDatabase(object):
         Dir = os.path.dirname(DbPath)\r
         if not os.path.isdir(Dir):\r
             os.mkdir(Dir)\r
-        self.Conn = sqlite3.connect(unicode(DbPath), isolation_level='DEFERRED')\r
+        self.Conn = sqlite3.connect(u''.join(DbPath), isolation_level='DEFERRED')\r
         self.Conn.execute("PRAGMA page_size=4096")\r
         self.Conn.execute("PRAGMA synchronous=OFF")\r
         self.Cur = self.Conn.cursor()\r
@@ -921,7 +921,7 @@ class IpiDatabase(object):
     def __ConvertToSqlString(self, StringList):\r
         if self.DpTable:\r
             pass\r
-        return map(lambda s: s.replace("'", "''"), StringList)\r
+        return list(map(lambda s: s.replace("'", "''"), StringList))\r
 \r
 \r
 \r