diff options
author | Erich Eckner <git@eckner.net> | 2015-10-23 16:38:47 +0200 |
---|---|---|
committer | Erich Eckner <git@eckner.net> | 2015-10-23 16:38:47 +0200 |
commit | 8a0a2266adfb7b85797a4b867bc0753cb94a2d3a (patch) | |
tree | 3be98fc1b70a921142631ca72c973c0afc8d4cf8 | |
parent | 39f0775faf3ad8a60282bd82a58a9e3f81fbc750 (diff) | |
download | units-8a0a2266adfb7b85797a4b867bc0753cb94a2d3a.tar.xz |
lowlevelunit.pas vertraegt jetzt auch, wenn Logdatei nicht geschrieben werden kann
-rw-r--r-- | lowlevelunit.pas | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/lowlevelunit.pas b/lowlevelunit.pas index 6ca3c15..6f59733 100644 --- a/lowlevelunit.pas +++ b/lowlevelunit.pas @@ -528,8 +528,12 @@ var f: textfile; begin id:=getThreadID; assignfile(f,'Log'+inttostr(id)); - if fileexists('Log'+inttostr(id)) then append(f) - else rewrite(f); + try + if fileexists('Log'+inttostr(id)) then append(f) + else rewrite(f); + except + exit; + end; writeln(f,inttostr(id)+': '+s); closefile(f); end; |