MCPcopy Create free account
hub / github.com/ELMERIKH/PyinMemoryPE / close

Method close

windows/native_exec/native_function.py:58–67  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

56 return addr
57
58 def close(self):
59 maps = self.maps
60 self.maps = []
61 self.cur_offset = 0
62 self.cur_page_size = 0
63 if getattr(sys, "path", None) is None:
64 # Path is None -> Python shutdown
65 return
66 for mymap in maps:
67 windows.winproxy.VirtualFree(mymap.addr, dwFreeType=gdef.MEM_RELEASE)
68
69 def __del__(self):
70 self.close()

Callers 1

__del__Method · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected