TraceThreadListener::~TraceThreadListener() { traceWrite(); traceFlush(); traceClose(); ProcessListener.deregisterThreadListener(ThreadID); }
/* returns NO if enabling tracing before setting the trace file */ BOOL setTraceEnb(BOOL enb) { if (enb) { if (!tracef) return NO; preInst |= PRE_TRACE; traceEnb = YES; } else { preInst &= ~PRE_TRACE; traceEnb = NO; traceFlush(tracef); } return YES; }