Skip to content

Commit

Permalink
Fix dr_insert_clean_call callee arg in tutorial (#6111)
Browse files Browse the repository at this point in the history
Fixes the callee arg in the dr_insert_clean_call call in the dynamic
basic block size tutorial. The callee pointer should be cast to `void*`
for it to compile successfully.

Related to: https://groups.google.com/g/dynamorio-users/c/BWVdySjLUn8
  • Loading branch information
Pavel-Durov authored Sep 19, 2024
1 parent fd99b5e commit 659c666
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions api/docs/tutorial.dox
Original file line number Diff line number Diff line change
Expand Up @@ -300,8 +300,8 @@ event_basic_block(void *drcontext, void *tag, instrlist_t *bb,
dr_mutex_unlock(as_built_lock);

+ /* insert clean call */
+ dr_insert_clean_call(drcontext, bb, instrlist_first(bb), clean_call, false, 1,
+ OPND_CREATE_INT32(num_instructions));
+ dr_insert_clean_call(drcontext, bb, instrlist_first(bb), (void *)clean_call,
+ false, 1, OPND_CREATE_INT32(num_instructions));
+
return DR_EMIT_DEFAULT;
}
Expand Down

0 comments on commit 659c666

Please sign in to comment.