[Zope3-checkins] CVS: Zope3/src/zodb/storage - file.py:1.5.2.4
Jeremy Hylton
jeremy@zope.com
Thu, 23 Jan 2003 13:40:49 -0500
Update of /cvs-repository/Zope3/src/zodb/storage
In directory cvs.zope.org:/tmp/cvs-serv27094
Modified Files:
Tag: new-pickle-branch
file.py
Log Message:
Make sure comparison for 1st records is 0 != 0, not None != 0.
=== Zope3/src/zodb/storage/file.py 1.5.2.3 => 1.5.2.4 ===
--- Zope3/src/zodb/storage/file.py:1.5.2.3 Thu Jan 23 13:35:01 2003
+++ Zope3/src/zodb/storage/file.py Thu Jan 23 13:40:47 2003
@@ -357,13 +357,14 @@
return tpos, None, None
panic("%s data record exceeds transaction record at %s",
self._file.name, pos)
-
- if index.get(h.oid) != h.prev:
+
+ if index.get(h.oid, 0) != h.prev:
if h.prev:
if recover:
return tpos, None, None
- error("%s incorrect previous pointer at %s",
- self._file.name, pos)
+ error("%s incorrect previous pointer at %s: "
+ "index says %r record says %r",
+ self._file.name, pos, index.get(h.oid), h.prev)
pos += dlen