From dec92755b6bc99fabc448aa346dbecb5e25fd864 Mon Sep 17 00:00:00 2001 From: iceman1001 Date: Tue, 2 Jun 2020 13:04:23 +0200 Subject: [PATCH] cppchecker --- tools/hitag2crack/common/ht2crackutils.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/tools/hitag2crack/common/ht2crackutils.c b/tools/hitag2crack/common/ht2crackutils.c index 8b67cf789..ac492ffa0 100644 --- a/tools/hitag2crack/common/ht2crackutils.c +++ b/tools/hitag2crack/common/ht2crackutils.c @@ -190,7 +190,6 @@ unsigned long hexreversetoulong(char *hex) { // convert byte-reversed 12 digit hex to unsigned long unsigned long long hexreversetoulonglong(char *hex) { - unsigned long long ret = 0LL; char tmp[9]; // this may seem an odd way to do it, but weird compiler issues were @@ -199,7 +198,7 @@ unsigned long long hexreversetoulonglong(char *hex) { tmp[8] = '\0'; memset(tmp + 4, '0', 4); memcpy(tmp, hex + 8, 4); - ret = hexreversetoulong(tmp); + unsigned long long ret = hexreversetoulong(tmp); ret <<= 32; memcpy(tmp, hex, 8); ret += hexreversetoulong(tmp);