Finding bytes in a block...

B

barcaroller

Is there a C++ or Boost function that finds a sequence of (consecutive)
bytes within a larger block of memory? Something similar to STL's
string.find().
 
K

Kai-Uwe Bux

barcaroller said:
Is there a C++ or Boost function that finds a sequence of (consecutive)
bytes within a larger block of memory? Something similar to STL's
string.find().

In header <algorithm>, you will find std::search(). Of course, it takes
iterators to the needle and to the haystack, but pointers qualify.


Best

Kai-Uwe Bux
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,169
Messages
2,570,919
Members
47,458
Latest member
Chris#

Latest Threads

Top