From 14fa6ad9f9c92ef9e28311b4df5a02fdb0d1ec27 Mon Sep 17 00:00:00 2001 From: Andy Polyakov Date: Mon, 23 Aug 2004 22:19:51 +0000 Subject: [PATCH] Make aes_ctr.c 64-bit savvy. --- crypto/aes/aes_ctr.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/crypto/aes/aes_ctr.c b/crypto/aes/aes_ctr.c index 2487d83fb1..f36982be1e 100644 --- a/crypto/aes/aes_ctr.c +++ b/crypto/aes/aes_ctr.c @@ -68,7 +68,7 @@ static void AES_ctr128_inc(unsigned char *counter) { /* Grab bottom dword of counter and increment */ c = GETU32(counter + 12); - c++; + c++; c &= 0xFFFFFFFF; PUTU32(counter + 12, c); /* if no overflow, we're done */ @@ -77,7 +77,7 @@ static void AES_ctr128_inc(unsigned char *counter) { /* Grab 1st dword of counter and increment */ c = GETU32(counter + 8); - c++; + c++; c &= 0xFFFFFFFF; PUTU32(counter + 8, c); /* if no overflow, we're done */ @@ -86,7 +86,7 @@ static void AES_ctr128_inc(unsigned char *counter) { /* Grab 2nd dword of counter and increment */ c = GETU32(counter + 4); - c++; + c++; c &= 0xFFFFFFFF; PUTU32(counter + 4, c); /* if no overflow, we're done */ @@ -95,7 +95,7 @@ static void AES_ctr128_inc(unsigned char *counter) { /* Grab top dword of counter and increment */ c = GETU32(counter + 0); - c++; + c++; c &= 0xFFFFFFFF; PUTU32(counter + 0, c); } -- GitLab