From ba8597a69f3c180c705c226164e4d6662886a500 Mon Sep 17 00:00:00 2001 From: G0lge Date: Fri, 8 Mar 2024 07:21:47 +0300 Subject: [PATCH] Refactored utility function to be consistent with rest of the code --- tools/ZydisFuzzShared.c | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/tools/ZydisFuzzShared.c b/tools/ZydisFuzzShared.c index dade8474..baaa1e72 100644 --- a/tools/ZydisFuzzShared.c +++ b/tools/ZydisFuzzShared.c @@ -136,9 +136,15 @@ void ZydisPrintInstruction(const ZydisDecodedInstruction* instruction, #endif -void ZydisValidateImmediateSize(ZyanU64 value) { - if (value != 0 && value != 8 && value != 16 && value != 32 && value != 64) { - fprintf(stderr, "Value = 0x%016" PRIX64 " does not match any of the expected " +void ZydisValidateImmediateSize(ZyanU64 value) +{ + if ((value != 0) && + (value != 8) && + (value != 16) && + (value != 32) && + (value != 64)) + { + fprintf(stderr, "Value " #value " = 0x % 016" PRIX64 " does not match any of the expected " "values (0, 8, 16, 32, 64).\n", value); abort(); }