mirror of
https://github.com/chatmail/core.git
synced 2026-04-17 21:46:35 +03:00
fix(python): free allocated string pointers (#393)
* fix(python): free allocated string pointers * Update python/src/deltachat/cutil.py Co-Authored-By: holger krekel <holger@merlinux.eu> * Update cutil.py * probably the proper way to handle ffi.strings
This commit is contained in:
committed by
holger krekel
parent
6b2fe03d08
commit
8c10aa287c
@@ -16,4 +16,4 @@ def iter_array(dc_array_t, constructor):
|
||||
|
||||
|
||||
def from_dc_charpointer(obj):
|
||||
return ffi.string(obj).decode("utf8")
|
||||
return ffi.string(ffi.gc(obj, lib.dc_str_unref)).decode("utf8")
|
||||
|
||||
Reference in New Issue
Block a user