mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-12 16:29:21 +02:00
* fsplit with .. fix from Thomas (merged)
This commit is contained in:
parent
2f36898e80
commit
4072466464
@ -769,6 +769,8 @@ begin
|
|||||||
Begin
|
Begin
|
||||||
If (Path[i]='.') Then
|
If (Path[i]='.') Then
|
||||||
begin
|
begin
|
||||||
|
while (i>0) and (Path[i]='.') do
|
||||||
|
dec(i);
|
||||||
DotPos:=i;
|
DotPos:=i;
|
||||||
break;
|
break;
|
||||||
end;
|
end;
|
||||||
@ -1135,7 +1137,10 @@ End;
|
|||||||
end.
|
end.
|
||||||
{
|
{
|
||||||
$Log$
|
$Log$
|
||||||
Revision 1.6 2000-08-04 21:45:39 peter
|
Revision 1.7 2000-09-04 19:38:12 peter
|
||||||
|
* fsplit with .. fix from Thomas (merged)
|
||||||
|
|
||||||
|
Revision 1.6 2000/08/04 21:45:39 peter
|
||||||
* getenv case insensitive (merged)
|
* getenv case insensitive (merged)
|
||||||
|
|
||||||
Revision 1.4 2000/07/22 12:24:55 jonas
|
Revision 1.4 2000/07/22 12:24:55 jonas
|
||||||
|
@ -2556,7 +2556,11 @@ Begin
|
|||||||
While (i>0) and (SlashPos=0) Do
|
While (i>0) and (SlashPos=0) Do
|
||||||
Begin
|
Begin
|
||||||
If (DotPos=256) and (Path[i]='.') Then
|
If (DotPos=256) and (Path[i]='.') Then
|
||||||
DotPos:=i;
|
begin
|
||||||
|
while (i>0) and (Path[i]='.') do
|
||||||
|
dec(i);
|
||||||
|
DotPos:=i;
|
||||||
|
end;
|
||||||
If (Path[i]='/') Then
|
If (Path[i]='/') Then
|
||||||
SlashPos:=i;
|
SlashPos:=i;
|
||||||
Dec(i);
|
Dec(i);
|
||||||
@ -2931,7 +2935,10 @@ End.
|
|||||||
|
|
||||||
{
|
{
|
||||||
$Log$
|
$Log$
|
||||||
Revision 1.2 2000-07-13 11:33:48 michael
|
Revision 1.3 2000-09-04 19:38:13 peter
|
||||||
|
* fsplit with .. fix from Thomas (merged)
|
||||||
|
|
||||||
|
Revision 1.2 2000/07/13 11:33:48 michael
|
||||||
+ removed logs
|
+ removed logs
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -667,6 +667,8 @@ begin
|
|||||||
Begin
|
Begin
|
||||||
If (Path[i]='.') Then
|
If (Path[i]='.') Then
|
||||||
begin
|
begin
|
||||||
|
while (i>0) and (path[i]='.') do
|
||||||
|
dec(i);
|
||||||
DotPos:=i;
|
DotPos:=i;
|
||||||
break;
|
break;
|
||||||
end;
|
end;
|
||||||
@ -718,12 +720,14 @@ var temp : PChar;
|
|||||||
name : namestr;
|
name : namestr;
|
||||||
ext : extstr;
|
ext : extstr;
|
||||||
s : SearchRec;
|
s : SearchRec;
|
||||||
|
found : boolean;
|
||||||
begin
|
begin
|
||||||
{ check if the file specified exists }
|
{ check if the file specified exists }
|
||||||
findfirst(path,anyfile,s);
|
findfirst(path,anyfile,s);
|
||||||
if doserror=0 then
|
found:=(doserror=0);
|
||||||
|
findclose(s);
|
||||||
|
if found then
|
||||||
begin
|
begin
|
||||||
findclose(s);
|
|
||||||
fsearch:=path;
|
fsearch:=path;
|
||||||
exit;
|
exit;
|
||||||
end;
|
end;
|
||||||
@ -1014,7 +1018,10 @@ begin
|
|||||||
end.
|
end.
|
||||||
{
|
{
|
||||||
$Log$
|
$Log$
|
||||||
Revision 1.3 2000-08-24 19:02:36 peter
|
Revision 1.4 2000-09-04 19:38:13 peter
|
||||||
|
* fsplit with .. fix from Thomas (merged)
|
||||||
|
|
||||||
|
Revision 1.3 2000/08/24 19:02:36 peter
|
||||||
* fsearch checks if file exists first (merged)
|
* fsearch checks if file exists first (merged)
|
||||||
|
|
||||||
Revision 1.2 2000/07/13 11:33:57 michael
|
Revision 1.2 2000/07/13 11:33:57 michael
|
||||||
|
Loading…
Reference in New Issue
Block a user