mirror of
https://github.com/doublecmd/doublecmd.git
synced 2026-06-21 09:58:13 +00:00
UPD: FixExeExt - keep untouched non exe extensions
This commit is contained in:
parent
d174021001
commit
947ac3b82f
1 changed files with 4 additions and 2 deletions
|
|
@ -660,11 +660,13 @@ end;
|
|||
|
||||
function FixExeExt(const sFileName: String): String;
|
||||
var
|
||||
ExeExt: String;
|
||||
ExeExt, FileExt: String;
|
||||
begin
|
||||
Result:= sFileName;
|
||||
ExeExt:= GetExeExt;
|
||||
if not SameText(ExeExt, ExtractFileExt(sFileName)) then
|
||||
FileExt:= ExtractFileExt(sFileName);
|
||||
if (SameText(ExeExt, '.exe') and (FileExt = EmptyStr)) or
|
||||
((ExeExt = EmptyStr) and SameText(FileExt, '.exe')) then
|
||||
Result:= ChangeFileExt(sFileName, ExeExt);
|
||||
end;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue