]> andersk Git - openssh.git/commitdiff
- pvalchev@cvs.openbsd.org 2008/05/12 20:52:20
authordjm <djm>
Mon, 19 May 2008 06:07:45 +0000 (06:07 +0000)
committerdjm <djm>
Mon, 19 May 2008 06:07:45 +0000 (06:07 +0000)
     [umac.c]
     Ensure nh_result lies on a 64-bit boundary (fixes warnings observed
     on Itanium on Linux); from Dale Talcott (bug #1462); ok djm@

ChangeLog
umac.c

index 702b488408e4a7f20e951969e37f793dfdac377e..fc0739a92fd131549f1bc37e11d80888d3729f29 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
      ignoring SIGPIPE by adding a new channel message (EOW) that signals
      the peer that we're not interested in any data it might send.
      fixes bz #85; discussion, debugging and ok djm@
+   - pvalchev@cvs.openbsd.org 2008/05/12 20:52:20
+     [umac.c]
+     Ensure nh_result lies on a 64-bit boundary (fixes warnings observed
+     on Itanium on Linux); from Dale Talcott (bug #1462); ok djm@
 
 20080403
  - (djm) [openbsd-compat/bsd-poll.c] Include stdlib.h to avoid compile-
diff --git a/umac.c b/umac.c
index ca5e08b3e2671b4edb3770b4d2ff8da199bbd724..6b5a00585a0a5c4be5603b39c490822d93c9268e 100644 (file)
--- a/umac.c
+++ b/umac.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: umac.c,v 1.2 2007/09/12 19:39:19 stevesk Exp $ */
+/* $OpenBSD: umac.c,v 1.3 2008/05/12 20:52:20 pvalchev Exp $ */
 /* -----------------------------------------------------------------------
  * 
  * umac.c -- C Implementation UMAC Message Authentication
@@ -1043,7 +1043,8 @@ static int uhash_update(uhash_ctx_t ctx, u_char *input, long len)
  */
 {
     UWORD bytes_hashed, bytes_remaining;
-    UINT8 nh_result[STREAMS*sizeof(UINT64)];
+    UINT64 result_buf[STREAMS];
+    UINT8 *nh_result = (UINT8 *)&result_buf;
     
     if (ctx->msg_len + len <= L1_KEY_LEN) {
         nh_update(&ctx->hash, (UINT8 *)input, len);
@@ -1095,7 +1096,8 @@ static int uhash_update(uhash_ctx_t ctx, u_char *input, long len)
 static int uhash_final(uhash_ctx_t ctx, u_char *res)
 /* Incorporate any pending data, pad, and generate tag */
 {
-    UINT8 nh_result[STREAMS*sizeof(UINT64)];
+    UINT64 result_buf[STREAMS];
+    UINT8 *nh_result = (UINT8 *)&result_buf;
 
     if (ctx->msg_len > L1_KEY_LEN) {
         if (ctx->msg_len % L1_KEY_LEN) {
This page took 0.819603 seconds and 5 git commands to generate.