Browse Source

* Better length check

Michaël Van Canneyt 2 years ago
parent
commit
8af6fdefa8
1 changed files with 5 additions and 2 deletions
  1. 5 2
      rtl/inc/exeinfo.pp

+ 5 - 2
rtl/inc/exeinfo.pp

@@ -84,8 +84,11 @@ var
 
 begin
   ReadDebugLink:=ReadDebugLink(e,fn);
-  if ReadDebugLink and (length(fn)<256) then
-    dbgfn:=fn;
+  if ReadDebugLink then
+    if (length(fn)<256) then
+      dbgfn:=fn
+    else
+      ReadDebugLink:=False;
 end;