diff --git a/rtl/os2/dos.pas b/rtl/os2/dos.pas index 769a3e41d8..d5d12b06f1 100644 --- a/rtl/os2/dos.pas +++ b/rtl/os2/dos.pas @@ -729,7 +729,7 @@ begin else begin OSErrorWatch (RC); - if FileRec (F).Name = '' then + if FileRec (F).Name [0] = #0 then DosError := 3; (* Align the returned error value to TP/BP *) end; end; @@ -762,7 +762,7 @@ begin else begin OSErrorWatch (RC); - if FileRec (F).Name = '' then + if FileRec (F).Name [0] = #0 then DosError := 3; (* Align the returned error value to TP/BP *) end; DosError := integer (RC);