diff options
Diffstat (limited to 'newlib/libc/string/bzero.c')
-rw-r--r-- | newlib/libc/string/bzero.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/newlib/libc/string/bzero.c b/newlib/libc/string/bzero.c index e9e78c938..661285f7b 100644 --- a/newlib/libc/string/bzero.c +++ b/newlib/libc/string/bzero.c @@ -7,12 +7,12 @@ INDEX ANSI_SYNOPSIS #include <string.h> - void bzero(char *<[b]>, size_t <[length]>); + void bzero(void *<[b]>, size_t <[length]>); TRAD_SYNOPSIS #include <string.h> void bzero(<[b]>, <[length]>) - char *<[b]>; + void *<[b]>; size_t <[length]>; DESCRIPTION @@ -34,9 +34,10 @@ Neither ANSI C nor the System V Interface Definition (Issue 2) require _VOID _DEFUN (bzero, (b, length), - char *b _AND + void *b _AND size_t length) { + char *ptr = (char *)b; while (length--) - *b++ = 0; + *ptr++ = 0; } |