mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-12-09 22:31:22 +01:00
* fcl-db/dbase: fix for dbf_common Memscan fixes DBase3 memo issues. Thanks to J.G. Johansen
git-svn-id: trunk@24264 -
This commit is contained in:
parent
f97cd6997c
commit
1b942b52d4
@ -408,7 +408,9 @@ function MemScan(const Buffer: Pointer; Chr: Byte; Length: Integer): Pointer;
|
||||
var
|
||||
I: Integer;
|
||||
begin
|
||||
I := System.IndexByte(Buffer, Length, Chr);
|
||||
// Make sure we pass a buffer of bytes instead of a pchar otherwise
|
||||
// the call will always fail
|
||||
I := System.IndexByte(PByte(Buffer)^, Length, Chr);
|
||||
if I = -1 then
|
||||
Result := nil
|
||||
else
|
||||
|
||||
Loading…
Reference in New Issue
Block a user