search for a given byte in the stream, and remain positioned on it
| 559 | |
| 560 | // search for a given byte in the stream, and remain positioned on it |
| 561 | void FindByte(char ch) { |
| 562 | while (true) { |
| 563 | if (nReadPos == nSrcPos) |
| 564 | Fill(); |
| 565 | if (vchBuf[nReadPos % vchBuf.size()] == ch) |
| 566 | break; |
| 567 | nReadPos++; |
| 568 | } |
| 569 | } |
| 570 | }; |
| 571 | |
| 572 | #endif // BITCOIN_STREAMS_H |
no test coverage detected