Skip to content

Commit

Permalink
SKIPDATA: add info about the first argument of callback function
Browse files Browse the repository at this point in the history
  • Loading branch information
aquynh committed Apr 14, 2014
1 parent 2daab25 commit 1efa9c1
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions include/capstone.h
Original file line number Diff line number Diff line change
Expand Up @@ -105,10 +105,12 @@ typedef enum cs_opt_value {
} cs_opt_value;

// User-defined callback function for SKIPDATA option
// @offset: the position of the currently-examining data in the input buffer
// passed to cs_disasm_ex().
// @code: the input buffer containing code to be disassembled. This is the
// same buffer passed to cs_disasm_ex().
// @offset: the position of the currently-examining byte in the input
// buffer @code mentioned above.
// @user_data: user-data passed to cs_option() via @user_data field in
// cs_opt_skipdata struct below.
// cs_opt_skipdata struct below.
// @return: return number of bytes to skip, or 0 to immediately stop disassembling.
typedef size_t (*cs_skipdata_cb_t)(const uint8_t *code, size_t offset, void* user_data);

Expand Down

0 comments on commit 1efa9c1

Please sign in to comment.