Commit 19528fed authored by Kirill Smelkov's avatar Kirill Smelkov

.

parent b89dd7f8
......@@ -51,7 +51,7 @@ cdef extern from * nogil:
import wcfs as pywcfs
from wcfs.client cimport _wcfs as wcfs
from golang cimport nil
from golang cimport error, nil, pyerror
from cpython cimport PyCapsule_New
from ZODB.Connection import Connection as ZConnection
......@@ -83,7 +83,12 @@ cdef public class _ZBigFile(BigFile) [object _ZBigFile, type _ZBigFile_Type]:
return obj
def __dealloc__(_ZBigFile zf):
zf.wfileh = nil # XXX where it should be closed?
cdef error err = nil
if zf.wfileh != nil:
err = zf.wfileh.close()
zf.wfileh = nil
if err != nil:
raise pyerror.from_error(err)
# redirect load/store to main class
......
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