From ac8082b7387985c68eaada39d14399496dbcd42d Mon Sep 17 00:00:00 2001 From: Ezra Peisach Date: Fri, 10 May 1996 16:55:07 +0000 Subject: [PATCH] * shs.c (longReverse): Remove extraneous \. (expand): Start #define in first column. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@7976 dc483132-0cff-0310-8789-dd5450dbe970 --- src/lib/crypto/sha/ChangeLog | 5 +++++ src/lib/crypto/sha/shs.c | 6 +++--- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/src/lib/crypto/sha/ChangeLog b/src/lib/crypto/sha/ChangeLog index 2cb3cf5f9..d7331b49f 100644 --- a/src/lib/crypto/sha/ChangeLog +++ b/src/lib/crypto/sha/ChangeLog @@ -1,3 +1,8 @@ +Fri May 10 11:19:53 1996 Ezra Peisach + + * shs.c (longReverse): Remove extraneous \. + (expand): Start #define in first column. + Fri May 10 01:19:18 1996 Richard Basch * Makefile.in configure.in t_shs.c sha_glue.c sha_crypto.c shs.c shs.h: diff --git a/src/lib/crypto/sha/shs.c b/src/lib/crypto/sha/shs.c index ed6ee8de6..2b2f9bf97 100644 --- a/src/lib/crypto/sha/shs.c +++ b/src/lib/crypto/sha/shs.c @@ -48,10 +48,10 @@ for this information */ #ifdef NEW_SHS - #define expand(W,i) ( W[ i & 15 ] = ROTL( 1, ( W[ i & 15 ] ^ W[ i - 14 & 15 ] ^ \ +#define expand(W,i) ( W[ i & 15 ] = ROTL( 1, ( W[ i & 15 ] ^ W[ i - 14 & 15 ] ^ \ W[ i - 8 & 15 ] ^ W[ i - 3 & 15 ] ) ) ) #else - #define expand(W,i) ( W[ i & 15 ] ^= W[ i - 14 & 15 ] ^ W[ i - 8 & 15 ] ^ W[ i - 3 & 15 ] ) +#define expand(W,i) ( W[ i & 15 ] ^= W[ i - 14 & 15 ] ^ W[ i - 8 & 15 ] ^ W[ i - 3 & 15 ] ) #endif /* NEW_SHS */ /* The prototype SHS sub-round. The fundamental sub-round is: @@ -230,7 +230,7 @@ void longReverse( LONG *buffer, int byteCount ) byteCount /= sizeof( LONG ); while( byteCount-- ) { value = *buffer; - value = ( ( value & 0xFF00FF00L ) >> 8 ) | \ + value = ( ( value & 0xFF00FF00L ) >> 8 ) | ( ( value & 0x00FF00FFL ) << 8 ); *buffer++ = ( value << 16 ) | ( value >> 16 ); } -- 2.26.2