diff --git a/Units/MMLAddon/mmlpsthread.pas b/Units/MMLAddon/mmlpsthread.pas index d8dfc7d..8b32a7c 100644 --- a/Units/MMLAddon/mmlpsthread.pas +++ b/Units/MMLAddon/mmlpsthread.pas @@ -288,7 +288,7 @@ end; procedure ps_DebugLn(str : string); extdecl; begin - if CurrThread.Prop.WriteTimeStamp then + if Assigned(CurrThread) and CurrThread.Prop.WriteTimeStamp then str := format('[%s]: %s', [TimeToStr(TimeStampToDateTime(MSecsToTimeStamp(GetTickCount - CurrThread.StartTime))), str]); mDebugLn(str); end;