[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
error: invalid use of void expression
From: |
Bruce Korb |
Subject: |
error: invalid use of void expression |
Date: |
Fri, 04 Jan 2013 16:47:29 -0800 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/17.0 Thunderbird/17.0 |
You may have been thinking you were using "memcpy", but you were
using "bcopy" instead. Please apply the patch to md5.c. Thanks!
$ gcc -c shar-i.c
shar-i.c: In function 'md5_process_bytes':
shar-i.c:3087:13: error: invalid use of void expression
1034 extern void bcopy (__const void *__src, void *__dest, size_t __n)
1035 __attribute__ ((__nothrow__ , __leaf__)) __attribute__
((__nonnull__ (1, 2)));
3082 if (len >= 64)
3083 {
3084 if (((uintptr_t) (buffer) % _Alignof (uint32_t) != 0))
3085 while (len > 64)
3086 {
3087 md5_process_block (bcopy (buffer, ctx->buffer, 64), 64,
ctx);
3088 buffer = (const char *) buffer + 64;
3089 len -= 64;
3090 }
In file included from shar.c:55:0:
../lib/md5.c: In function 'md5_process_bytes':
../lib/md5.c:261:13: error: invalid use of void expression
254 if (len >= 64)
255 {
256 #if !_STRING_ARCH_unaligned
257 # define UNALIGNED_P(p) ((uintptr_t) (p) % alignof (uint32_t) != 0)
258 if (UNALIGNED_P (buffer))
259 while (len > 64)
260 {
261 md5_process_block (memcpy (ctx->buffer, buffer, 64), 64,
ctx);
262 buffer = (const char *) buffer + 64;
263 len -= 64;
264 }
265 else
- error: invalid use of void expression,
Bruce Korb <=