diff options
author | lgao4 <lgao4@6f19259b-4bc3-4df7-8a09-765794883524> | 2011-08-26 07:46:26 +0000 |
---|---|---|
committer | lgao4 <lgao4@6f19259b-4bc3-4df7-8a09-765794883524> | 2011-08-26 07:46:26 +0000 |
commit | 4234283c3acb8c35014acc1546621fbc2621b095 (patch) | |
tree | 208a4f87b2820ec1f3a414508ca1c215c5deed18 /BaseTools/Source/Python/Workspace | |
parent | ba944801a988dddf3ed217c72c8d880d0f03d150 (diff) | |
download | edk2-platforms-4234283c3acb8c35014acc1546621fbc2621b095.tar.xz |
Sync BaseTools Branch (version r2271) to EDKII main trunk.
BaseTool Branch:
https://edk2-buildtools.svn.sourceforge.net/svnroot/edk2-buildtools/branches/Releases/BaseTools_r2100
Signed-off-by: lgao4
Reviewed-by: hchen30
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@12214 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'BaseTools/Source/Python/Workspace')
-rw-r--r-- | BaseTools/Source/Python/Workspace/WorkspaceDatabase.py | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/BaseTools/Source/Python/Workspace/WorkspaceDatabase.py b/BaseTools/Source/Python/Workspace/WorkspaceDatabase.py index 4a97b8a93b..f923129c54 100644 --- a/BaseTools/Source/Python/Workspace/WorkspaceDatabase.py +++ b/BaseTools/Source/Python/Workspace/WorkspaceDatabase.py @@ -2261,6 +2261,7 @@ class WorkspaceDatabase(object): # @prarm RenewDb=False Create new database file if it's already there
#
def __init__(self, DbPath, GlobalMacros={}, RenewDb=False):
+ self._DbClosedFlag = False
self._GlobalMacros = GlobalMacros
if DbPath == None or DbPath == '':
@@ -2414,9 +2415,11 @@ determine whether database file is out of date!\n") # Close the connection and cursor
#
def Close(self):
- self.Conn.commit()
- self.Cur.close()
- self.Conn.close()
+ if not self._DbClosedFlag:
+ self.Conn.commit()
+ self.Cur.close()
+ self.Conn.close()
+ self._DbClosedFlag = True
## Get unique file ID for the gvien file
def GetFileId(self, FilePath):
|