mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-29 12:30:36 +02:00
* LCL: fixed ExtractFileNameWithoutExt and test (issue #14470)
git-svn-id: trunk@21564 -
This commit is contained in:
parent
c01962c0c6
commit
27c55c7a84
@ -621,7 +621,7 @@ begin
|
||||
while (p>0) do begin
|
||||
case Result[p] of
|
||||
PathDelim: exit;
|
||||
'.': Result:=copy(Result,1, p-1);
|
||||
'.': exit(copy(Result,1, p-1));
|
||||
end;
|
||||
dec(p);
|
||||
end;
|
||||
|
@ -44,10 +44,10 @@ var
|
||||
end;
|
||||
begin
|
||||
DoTest('test.pas', 'test');
|
||||
DoTest('test.pas.bak', 'test');
|
||||
DoTest('test.pas.bak', 'test.pas');
|
||||
DirName := AppendPathDelim('testdir');
|
||||
DoTest(DirName + 'test.pas', DirName + 'test');
|
||||
DoTest(DirName + 'test.pas.bak', DirName + 'test');
|
||||
DoTest(DirName + 'test.pas.bak', DirName + 'test.pas');
|
||||
end;
|
||||
|
||||
procedure TTestFileUtil.TestTrimFileName;
|
||||
|
Loading…
Reference in New Issue
Block a user