Commit fc0848d2 authored by Jim Fulton's avatar Jim Fulton

- Fixed bug that could lead to memory errors due to the use

  of a Python disctionary for a mapping that can grow large.

(Not large enough to use a lot of memory, but large enough to cause
  malloc to fail. :()
parent 11ac83e5
...@@ -44,6 +44,8 @@ from ZODB.FileStorage.format import CorruptedDataError ...@@ -44,6 +44,8 @@ from ZODB.FileStorage.format import CorruptedDataError
from ZODB.loglevels import BLATHER from ZODB.loglevels import BLATHER
from ZODB.fsIndex import fsIndex from ZODB.fsIndex import fsIndex
import BTrees.OOBTree
packed_version = "FS21" packed_version = "FS21"
logger = logging.getLogger('ZODB.FileStorage') logger = logging.getLogger('ZODB.FileStorage')
...@@ -222,7 +224,7 @@ class FileStorage(BaseStorage.BaseStorage, ...@@ -222,7 +224,7 @@ class FileStorage(BaseStorage.BaseStorage,
def _newIndexes(self): def _newIndexes(self):
# hook to use something other than builtin dict # hook to use something other than builtin dict
return fsIndex(), {}, {}, {}, {} return fsIndex(), {}, BTrees.OOBTree.OOBTree(), {}, {}
_saved = 0 _saved = 0
def _save_index(self): def _save_index(self):
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment