Fixed compiler warnings to make code compile with gcc's -pedantic switch

This commit is contained in:
adamdunkels 2007-11-17 18:01:00 +00:00
parent 607d27e0c6
commit 1e1e44a3f8
42 changed files with 313 additions and 286 deletions

View file

@ -33,7 +33,7 @@
*
* This file is part of the Contiki operating system.
*
* $Id: rimebuf.c,v 1.9 2007/10/25 12:48:46 adamdunkels Exp $
* $Id: rimebuf.c,v 1.10 2007/11/17 18:05:21 adamdunkels Exp $
*/
/**
@ -75,7 +75,7 @@ rimebuf_clear(void)
}
/*---------------------------------------------------------------------------*/
int
rimebuf_copyfrom(const u8_t *from, u16_t len)
rimebuf_copyfrom(const void *from, u16_t len)
{
u16_t l;
@ -117,7 +117,7 @@ rimebuf_copyto_hdr(u8_t *to)
}
/*---------------------------------------------------------------------------*/
int
rimebuf_copyto(u8_t *to)
rimebuf_copyto(void *to)
{
#if DEBUG_LEVEL > 0
{
@ -139,7 +139,7 @@ rimebuf_copyto(u8_t *to)
}
#endif /* DEBUG_LEVEL */
memcpy(to, rimebuf + hdrptr, RIMEBUF_HDR_SIZE - hdrptr);
memcpy(to + RIMEBUF_HDR_SIZE - hdrptr, rimebufptr + bufptr,
memcpy((u8_t *)to + RIMEBUF_HDR_SIZE - hdrptr, rimebufptr + bufptr,
buflen);
return RIMEBUF_HDR_SIZE - hdrptr + buflen;
}