Add files via upload
This commit is contained in:
parent
f166a5dca3
commit
2d5bb4faf1
1 changed files with 13 additions and 7 deletions
|
@ -159,6 +159,7 @@ cdef class PyGenericComparator(PyComparator):
|
|||
|
||||
def __dealloc__(self):
|
||||
if not self.comparator_ptr == NULL:
|
||||
with nogil:
|
||||
del self.comparator_ptr
|
||||
|
||||
cdef object get_ob(self):
|
||||
|
@ -771,6 +772,7 @@ cdef class _ColumnFamilyHandle:
|
|||
|
||||
def __dealloc__(self):
|
||||
if not self.handle == NULL:
|
||||
with nogil:
|
||||
del self.handle
|
||||
|
||||
@staticmethod
|
||||
|
@ -879,6 +881,7 @@ cdef class ColumnFamilyOptions(object):
|
|||
|
||||
def __dealloc__(self):
|
||||
if not self.copts == NULL:
|
||||
with nogil:
|
||||
del self.copts
|
||||
|
||||
def __init__(self, **kwargs):
|
||||
|
@ -1290,7 +1293,8 @@ cdef class Options(ColumnFamilyOptions):
|
|||
|
||||
def __dealloc__(self):
|
||||
if not self.opts == NULL:
|
||||
self.copts = NULL
|
||||
with nogil:
|
||||
del self.copts
|
||||
del self.opts
|
||||
|
||||
def __init__(self, **kwargs):
|
||||
|
@ -1551,6 +1555,7 @@ cdef class WriteBatch(object):
|
|||
|
||||
def __dealloc__(self):
|
||||
if not self.batch == NULL:
|
||||
with nogil:
|
||||
del self.batch
|
||||
|
||||
def put(self, key, value):
|
||||
|
@ -2305,6 +2310,7 @@ cdef class BaseIterator(object):
|
|||
|
||||
def __dealloc__(self):
|
||||
if not self.ptr == NULL:
|
||||
with nogil:
|
||||
del self.ptr
|
||||
|
||||
def __iter__(self):
|
||||
|
|
Loading…
Reference in a new issue