Minor bugfixes

This commit is contained in:
flobernd 2017-06-25 23:29:42 +02:00
parent 83699fe9d0
commit 3b45ae2f1d
2 changed files with 2 additions and 2 deletions

View File

@ -632,7 +632,7 @@ static ZydisStatus ZydisReadImmediate(ZydisDecoderContext* context, ZydisInstruc
ZYDIS_ASSERT(context);
ZYDIS_ASSERT(info);
ZYDIS_ASSERT((id == 0) || (id == 1));
ZYDIS_ASSERT(isSigned || ~isRelative);
ZYDIS_ASSERT(isSigned || !isRelative);
ZYDIS_ASSERT(info->details.imm[id].dataSize == 0);
info->details.imm[id].dataSize = size;

View File

@ -508,7 +508,7 @@ void ZydisGetElementInfo(ZydisInternalElementType element, ZydisElementType* typ
{ ZYDIS_ELEMENT_TYPE_LONGBCD , 80 }
};
ZYDIS_ASSERT((element >= 0) && (element < ZYDIS_ARRAY_SIZE(lookup)));
ZYDIS_ASSERT(element < ZYDIS_ARRAY_SIZE(lookup));
*type = lookup[element].type;
*size = lookup[element].size;