mirror of
https://git.openldap.org/openldap/openldap.git
synced 2025-12-26 01:29:59 -05:00
Use uint32 not u_int as code requires 32 bit unsigned integers.
This commit is contained in:
parent
7a2044dbda
commit
ebc4a8f149
1 changed files with 5 additions and 4 deletions
|
|
@ -20,6 +20,9 @@
|
|||
* 34AA973C D4C4DAA4 F61EEB2B DBAD2731 6534016F
|
||||
*/
|
||||
|
||||
/*
|
||||
* This code assumes uint32 is 32 bits and char is 8 bits
|
||||
*/
|
||||
|
||||
#include "portable.h"
|
||||
#include <ac/string.h>
|
||||
|
|
@ -67,13 +70,11 @@ lutil_SHA1Transform( uint32 *state, const unsigned char *buffer )
|
|||
{
|
||||
uint32 a, b, c, d, e;
|
||||
|
||||
/* Assumes u_int is 32 bits and char 8 bits.
|
||||
* I don't know why uint32 isn't used (or what the difference is). */
|
||||
#ifdef SHA1HANDSOFF
|
||||
u_int block[16];
|
||||
uint32 block[16];
|
||||
(void)memcpy(block, buffer, 64);
|
||||
#else
|
||||
u_int *block = (u_int *)buffer;
|
||||
uint32 *block = (u_int32 *) buffer;
|
||||
#endif
|
||||
|
||||
/* Copy context->state[] to working vars */
|
||||
|
|
|
|||
Loading…
Reference in a new issue