[Zodb-checkins] CVS: ZODB3/ZODB - FileStorage.py:1.105.2.1
Barry Warsaw
barry@wooz.org
Fri, 11 Oct 2002 17:59:31 -0400
Update of /cvs-repository/ZODB3/ZODB
In directory cvs.zope.org:/tmp/cvs-serv4283
Modified Files:
Tag: ZODB3-3_1-branch
FileStorage.py
Log Message:
restore(): We were never reading the pointer to the non-version data!
So pnv was always None, which caused abortVersion to fail when the
object being aborted had its non-version restore() instead of
store()d.
We could use a test case for this, and this should probably be ported
to the trunk. I'll let Jeremy verify the patch first.
=== ZODB3/ZODB/FileStorage.py 1.105 => 1.105.2.1 ===
--- ZODB3/ZODB/FileStorage.py:1.105 Sat Sep 28 23:40:37 2002
+++ ZODB3/ZODB/FileStorage.py Fri Oct 11 17:59:30 2002
@@ -778,6 +778,9 @@
h)
if doid != oid:
raise CorruptedDataError, h
+ if vlen > 0:
+ # non-version data pointer
+ pnv = self._file.read(8)
# Calculate the file position in the temporary file
here = self._pos + self._tfile.tell() + self._thl
# And update the temp file index