Skip to content

Commit 392484c

Browse files
committed
Add some more information about ERROR_BLOCK_NOT_READY to the documentation.
1 parent f8a4f14 commit 392484c

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

docs/capi.rst

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -897,8 +897,12 @@ Functions
897897
898898
Scan a serie of memory blocks that are provided by a :c:type:`YR_MEMORY_BLOCK_ITERATOR`.
899899
The iterator has a pair of `first` and `next` functions, that must return
900-
the first and next blocks respectively. The how the data is split in blocks is
901-
up to the iterator implementation.
900+
the first and next blocks respectively. If the iterator returns :c:macro:`ERROR_BLOCK_NOT_READY`
901+
from `first` or `next`, `yr_scanner_scan_mem_blocks` also returns :c:macro:`ERROR_BLOCK_NOT_READY`,
902+
but the scanner maintains its state and this function can be called again with
903+
the same iterator for retrying the operation. This can be done multiple times
904+
until the block is ready and the iterator is able to return it, which allows
905+
`yr_scanner_scan_mem_blocks` finish the scanning.
902906
903907
Returns one of the following error codes:
904908

0 commit comments

Comments
 (0)