mirror of
https://github.com/doublecmd/doublecmd.git
synced 2026-06-21 09:58:13 +00:00
FIX: Crash with empty file name (fixes #2631)
This commit is contained in:
parent
f27b7f8526
commit
ca615d4c84
1 changed files with 6 additions and 2 deletions
|
|
@ -1621,10 +1621,14 @@ begin
|
|||
Result := mbFileGetAttr(Path) <> faInvalidAttributes;
|
||||
end;
|
||||
|
||||
function mbCompareFileNames(const FileName1, FileName2: String): Boolean; inline;
|
||||
function mbCompareFileNames(const FileName1, FileName2: String): Boolean;
|
||||
{$IF DEFINED(DARWIN)}
|
||||
begin
|
||||
Result:= CompareFilenamesIgnoreCase(FileName1, FileName2) = 0;
|
||||
if (Length(FileName1) = 0) or (Length(FileName2) = 0) then
|
||||
Result:= (FileName1 = FileName2)
|
||||
else begin
|
||||
Result:= CompareFilenamesIgnoreCase(FileName1, FileName2) = 0;
|
||||
end;
|
||||
end;
|
||||
{$ELSEIF DEFINED(MSWINDOWS)}
|
||||
begin
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue