We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4bbd670 commit 920f2d2Copy full SHA for 920f2d2
mapbuffer/mapbuffer.py
@@ -47,7 +47,7 @@ def __init__(
47
if isinstance(data, dict):
48
self.buffer = self.dict2buf(data, compress)
49
elif isinstance(data, io.IOBase):
50
- self.buffer = mmap.mmap(f.fileno(), 0, prot=mmap.PROT_READ)
+ self.buffer = mmap.mmap(data.fileno(), 0, prot=mmap.PROT_READ)
51
elif isinstance(data, (bytes, mmap.mmap)):
52
self.buffer = data
53
else:
0 commit comments