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

Method set_context

windows/winobject/process.py:832–838  ·  view source on GitHub ↗

Set the thread's context to ``context``

(self, context)

Source from the content-addressed store, hash-verified

830
831
832 def set_context(self, context):
833 """Set the thread's context to ``context``"""
834 if self.owner.bitness == windows.current_process.bitness:
835 return winproxy.SetThreadContext(self.handle, context)
836 if windows.current_process.bitness == 64 and self.owner.bitness == 32:
837 return winproxy.Wow64SetThreadContext(self.handle, context)
838 return windows.syswow64.NtSetContextThread_32_to_64(self.handle, ctypes.byref(context))
839
840
841 def set_syswow_context(self, context):

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected