Python: Add VFS.fromEmpty utility
Vicki Pfau vi@endrift.com
Mon, 24 Aug 2020 01:59:28 -0700
1 files changed,
4 insertions(+),
0 deletions(-)
jump to
M
src/platform/python/mgba/vfs.py
→
src/platform/python/mgba/vfs.py
@@ -115,6 +115,10 @@ self.handle = vf
self._no_gc = _no_gc self._claimed = False + @staticmethod + def fromEmpty(): + return VFile(lib.VFileMemChunk(ffi.NULL, 0)) + def __del__(self): if not self._claimed: self.close()