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

Method __exit__

windows/winobject/event_trace.py:156–165  ·  view source on GitHub ↗
(self, exc_type, exc_value, traceback)

Source from the content-addressed store, hash-verified

154 return self.timing
155
156 def __exit__(self, exc_type, exc_value, traceback):
157 # bad_end = self._get_time()
158 self.trace.flush()
159 if self.stop:
160 self.trace.stop()
161 # End time after the flush is effective.
162 self.timing["end"] = self._get_time()
163 # print("Trace ctx: fake-end: {0:#x}".format(int(fake_end)))
164 print("Trace ctx: begin={0:#x} | end={1:#x}".format(int(self.timing["begin"]), int(self.timing["end"])))
165 self.trace.process(self.func, **self.timing)
166
167
168class EtwTrace(object):

Callers

nothing calls this directly

Calls 4

_get_timeMethod · 0.95
flushMethod · 0.80
stopMethod · 0.45
processMethod · 0.45

Tested by

no test coverage detected