move internal memory management declarations from utils.h to cs_priv.h

This commit is contained in:
Nguyen Anh Quynh 2014-01-05 11:35:47 +08:00
parent 24bf0d9079
commit c7404075ff
16 changed files with 11 additions and 26 deletions

View File

@ -20,12 +20,11 @@
#include "AArch64InstPrinter.h"
#include "AArch64BaseInfo.h"
#include "../../utils.h"
#include "../../MCInst.h"
#include "../../cs_priv.h"
#include "../../SStream.h"
#include "../../MCRegisterInfo.h"
#include "../../MathExtras.h"
#include "../../utils.h"
#include "mapping.h"

View File

@ -6,7 +6,6 @@
#include "../../include/arm64.h"
#include "../../utils.h"
#include "../../cs_priv.h"
#include "mapping.h"

View File

@ -1,7 +1,6 @@
/* Capstone Disassembler Engine */
/* By Dang Hoang Vu <danghvu@gmail.com> 2013 */
#include "../../cs_priv.h"
#include "../../utils.h"
#include "../../MCRegisterInfo.h"
#include "AArch64Disassembler.h"

View File

@ -29,7 +29,6 @@
#include "../../MCRegisterInfo.h"
#include "../../utils.h"
#include "mapping.h"
#include "../../cs_priv.h"
#define GET_SUBTARGETINFO_ENUM
#include "ARMGenSubtargetInfo.inc"

View File

@ -21,7 +21,7 @@
#include <inttypes.h>
#include "../../cs_priv.h"
#include "../../utils.h"
#include "../../SubtargetFeature.h"
#include "../../MCInst.h"
@ -29,7 +29,6 @@
#include "../../SStream.h"
#include "../../MathExtras.h"
#include "../../utils.h"
//#include "Mips.h"
//#include "MipsRegisterInfo.h"

View File

@ -21,10 +21,9 @@
#include "MipsInstPrinter.h"
#include "../../MCInst.h"
#include "../../cs_priv.h"
#include "../../utils.h"
#include "../../SStream.h"
#include "../../MCRegisterInfo.h"
#include "../../utils.h"
#include "mapping.h"
#include "MipsInstPrinter.h"

View File

@ -1,7 +1,6 @@
/* Capstone Disassembler Engine */
/* By Dang Hoang Vu <danghvu@gmail.com> 2013 */
#include "../../cs_priv.h"
#include "../../utils.h"
#include "../../MCRegisterInfo.h"
#include "MipsDisassembler.h"

View File

@ -21,11 +21,10 @@
#include "PPCInstPrinter.h"
#include "PPCPredicates.h"
#include "../../MCInst.h"
#include "../../cs_priv.h"
#include "../../utils.h"
#include "../../SStream.h"
#include "../../MCRegisterInfo.h"
#include "../../MathExtras.h"
#include "../../utils.h"
#include "mapping.h"
//#include "mapping.h"

View File

@ -6,7 +6,6 @@
#include "../../include/ppc.h"
#include "../../utils.h"
#include "../../cs_priv.h"
#include "mapping.h"

View File

@ -1,7 +1,6 @@
/* Capstone Disassembler Engine */
/* By Nguyen Anh Quynh <aquynh@gmail.com>, 2013 */
#include "../../cs_priv.h"
#include "../../utils.h"
#include "../../MCRegisterInfo.h"
#include "PPCDisassembler.h"

View File

@ -23,7 +23,6 @@
#include "../../utils.h"
#include "../../MCInst.h"
#include "../../cs_priv.h"
#include "../../SStream.h"
#include "../../MCRegisterInfo.h"
#include "mapping.h"

View File

@ -23,7 +23,6 @@
#include "../../utils.h"
#include "../../MCInst.h"
#include "../../cs_priv.h"
#include "../../SStream.h"
#include "mapping.h"

View File

@ -7,7 +7,6 @@
#include "X86DisassemblerDecoder.h"
#include "../../utils.h"
#include "../../cs_priv.h"
#include "../../include/x86.h"
static x86_reg sib_base_map[] = {

5
cs.c
View File

@ -7,11 +7,8 @@
#include <string.h>
#include <capstone.h>
#include "cs_priv.h"
#include "MCRegisterInfo.h"
#include "utils.h"
#include "MCRegisterInfo.h"
cs_err (*arch_init[MAX_ARCH])(cs_struct *) = { NULL };
cs_err (*arch_option[MAX_ARCH]) (cs_struct *, cs_opt_type, size_t value) = { NULL };

View File

@ -59,4 +59,9 @@ extern void (*arch_destroy[MAX_ARCH]) (cs_struct*);
extern unsigned int all_arch;
extern malloc_t my_malloc;
extern calloc_t my_calloc;
extern realloc_t my_realloc;
extern free_t my_free;
#endif

View File

@ -5,6 +5,7 @@
#define CS_UTILS_H
#include "include/capstone.h"
#include "cs_priv.h"
// threshold number, so above this number will be printed in hexa mode
#define HEX_THRESHOLD 9
@ -48,10 +49,5 @@ unsigned int count_positive(unsigned char *list);
#define ARR_SIZE(a) (sizeof(a)/sizeof(a[0]))
extern malloc_t my_malloc;
extern calloc_t my_calloc;
extern realloc_t my_realloc;
extern free_t my_free;
#endif