Minor refactorings and bug-fixes

This commit is contained in:
flobernd 2017-09-14 00:56:01 +02:00
parent 3b5906f40e
commit 30f15afe0a
5 changed files with 12 additions and 8 deletions

View File

@ -2203,7 +2203,7 @@ static void ZydisSetAccessedFlags(ZydisDecodedInstruction* instruction,
const ZydisAccessedFlags* flags;
ZydisGetAccessedFlags(definition, &flags);
ZYDIS_ASSERT(ZYDIS_ARRAY_SIZE(instruction->flags) == ZYDIS_ARRAY_SIZE(flags->action));
ZYDIS_ASSERT(ZYDIS_ARRAY_SIZE(instruction->accessedFlags) == ZYDIS_ARRAY_SIZE(flags->action));
memcpy(&instruction->accessedFlags, &flags->action, ZYDIS_ARRAY_SIZE(flags->action));
}

View File

@ -347,4 +347,6 @@ void ZydisGetInstructionEncodingInfo(const ZydisDecoderTreeNode* node,
*info = &instructionEncodings[class];
}
/* ---------------------------------------------------------------------------------------------- */
/* ============================================================================================== */

View File

@ -24,8 +24,8 @@
***************************************************************************************************/
#ifndef ZYDIS_INSTRUCTIONTABLE_H
#define ZYDIS_INSTRUCTIONTABLE_H
#ifndef ZYDIS_DECODERDATA_H
#define ZYDIS_DECODERDATA_H
#include <Zydis/Defines.h>
#include <Zydis/DecoderTypes.h>
@ -241,6 +241,8 @@ typedef struct ZydisInstructionEncodingInfo_
} imm[2];
} ZydisInstructionEncodingInfo;
/* ---------------------------------------------------------------------------------------------- */
/* ============================================================================================== */
/* Functions */
/* ============================================================================================== */
@ -285,4 +287,4 @@ ZYDIS_NO_EXPORT void ZydisGetInstructionEncodingInfo(const ZydisDecoderTreeNode*
}
#endif
#endif /* ZYDIS_INSTRUCTIONTABLE_H */
#endif /* ZYDIS_DECODERDATA_H */

View File

@ -30,9 +30,9 @@
/* Enum strings */
/* ============================================================================================== */
#include <Generated/EnumInstructionCategoryStrings.inc>
#include <Generated/EnumISASetStrings.inc>
#include <Generated/EnumISAExtStrings.inc>
#include <Generated/EnumInstructionCategory.inc>
#include <Generated/EnumISASet.inc>
#include <Generated/EnumISAExt.inc>
/* ============================================================================================== */
/* Exported functions */

View File

@ -30,7 +30,7 @@
/* Mnemonic strings */
/* ============================================================================================== */
#include <Generated/EnumMnemonicStrings.inc>
#include <Generated/EnumMnemonic.inc>
/* ============================================================================================== */
/* Exported functions */