What way is faster to check for a substring within a null-terminated string...
Posted on 2014-10-06
Hi guys... assuming I have an array of AnsiChar called "buffer" that contains some characters, and I want to find out if a certain substring "substr" exists within there, what would be the fastest/most efficient way to do it?
- do a "SearchBuf" command on the array of Char looking for "substr"
- or convert both "buffer" and "substr" to PChar, and do a AnsiStrPos command?
- or possibly some other way...?