Commit 3f36a085 authored by Guido van Rossum's avatar Guido van Rossum

Cast f.tell() result to int() in _addval(), so it works even on

platforms where tell() returns a long.  (Perhaps tell() should be
fixed too?)  Reported by Greg Humphreys.
parent 74109a14
......@@ -79,7 +79,7 @@ class _Database:
def _addval(self, val):
f = _open(self._datfile, 'rb+')
f.seek(0, 2)
pos = f.tell()
pos = int(f.tell())
## Does not work under MW compiler
## pos = ((pos + _BLOCKSIZE - 1) / _BLOCKSIZE) * _BLOCKSIZE
## f.seek(pos)
......
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