forked from capstone-engine/capstone
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
make vsnprintf() user-defined function pointer, which is passed in vi…
…a the same CS_OPT_MEM option like malloc/calloc etc
- Loading branch information
Showing
5 changed files
with
14 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -17,10 +17,11 @@ | |
/* By Nguyen Anh Quynh <[email protected]>, 2013> */ | ||
|
||
#include <stdarg.h> /* for va_*() */ | ||
#include <stdio.h> /* for vsnprintf() */ | ||
#include <stdlib.h> /* for exit() */ | ||
#include <string.h> /* for memset() */ | ||
|
||
#include "../../cs_priv.h" | ||
|
||
#include "X86DisassemblerDecoder.h" | ||
|
||
#include "X86GenDisassemblerTables.inc" | ||
|
@@ -282,7 +283,7 @@ static void dbgprintf(struct InternalInstruction* insn, | |
return; | ||
|
||
va_start(ap, format); | ||
(void)vsnprintf(buffer, sizeof(buffer), format, ap); | ||
(void)cs_vsnprintf(buffer, sizeof(buffer), format, ap); | ||
va_end(ap); | ||
|
||
insn->dlog(insn->dlogArg, buffer); | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters