From 21e6bc947ab6a11361e069fcd29a5b5f0559d78e Mon Sep 17 00:00:00 2001 From: 7YZ7 Date: Sun, 23 Apr 2023 20:07:15 +0800 Subject: [PATCH] Update wrapper.c --- components/utils/Bcrypt/src/wrapper.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/components/utils/Bcrypt/src/wrapper.c b/components/utils/Bcrypt/src/wrapper.c index 6bc34bc0..93c9a789 100644 --- a/components/utils/Bcrypt/src/wrapper.c +++ b/components/utils/Bcrypt/src/wrapper.c @@ -389,8 +389,8 @@ static void *run(void *arg) continue; if (strcmp(crypt_ra(key, hash, &data, &size), hash)) { - printf("%d: FAILED (crypt_ra/%d/%lu)\n", - (int)((char *)arg - (char *)0), i, count); + printf("%d: FAILED (crypt_ra/%d/%lu)\n", + (int)(intptr_t)arg, i, count); free(data); return NULL; } @@ -398,7 +398,7 @@ static void *run(void *arg) } while (running); free(data); - return count + (char *)0; + return (void *)(intptr_t)count; } int main(void)