mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-11-01 14:49:24 +01:00
* fixes from Luiz Am?rico
This commit is contained in:
parent
13a860eefc
commit
ed6ecf40db
@ -477,11 +477,11 @@ Function PosEx(const SubStr, S: string; Offset: Cardinal): Integer;
|
|||||||
var i : pchar;
|
var i : pchar;
|
||||||
begin
|
begin
|
||||||
if (offset<1) or (offset>length(s)) then exit(0);
|
if (offset<1) or (offset>length(s)) then exit(0);
|
||||||
i:=strpos(@s[1],@substr[offset]);
|
i:=strpos(@s[offset],@substr[1]);
|
||||||
if i=nil then
|
if i=nil then
|
||||||
PosEx:=0
|
PosEx:=0
|
||||||
else
|
else
|
||||||
PosEx:=(i-pchar(s))+offset;
|
PosEx:=succ(i-pchar(s));
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
|
||||||
@ -658,7 +658,10 @@ end.
|
|||||||
|
|
||||||
{
|
{
|
||||||
$Log$
|
$Log$
|
||||||
Revision 1.4 2004-03-19 12:54:22 marco
|
Revision 1.5 2004-05-17 07:33:01 marco
|
||||||
|
* fixes from Luiz Am?rico
|
||||||
|
|
||||||
|
Revision 1.4 2004/03/19 12:54:22 marco
|
||||||
* more strutils small things
|
* more strutils small things
|
||||||
|
|
||||||
Revision 1.3 2004/03/18 16:55:47 marco
|
Revision 1.3 2004/03/18 16:55:47 marco
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user