From 6331376531a8acab6c0317c27829e567a543eca5 Mon Sep 17 00:00:00 2001 From: Joel Rosdahl Date: Tue, 27 Apr 2010 08:18:16 +0200 Subject: [PATCH] Let hash_buffer take a void* to avoid some casting --- ccache.h | 2 +- hash.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/ccache.h b/ccache.h index dbf24cd..fad4fa0 100644 --- a/ccache.h +++ b/ccache.h @@ -60,7 +60,7 @@ int hash_fd(struct mdfour *md, int fd); int hash_file(struct mdfour *md, const char *fname); char *hash_result(struct mdfour *md); void hash_result_as_bytes(struct mdfour *md, unsigned char *out); -void hash_buffer(struct mdfour *md, const char *s, size_t len); +void hash_buffer(struct mdfour *md, const void *s, size_t len); void cc_log(const char *format, ...) ATTR_FORMAT(printf, 1, 2); void fatal(const char *format, ...) ATTR_FORMAT(printf, 1, 2); diff --git a/hash.c b/hash.c index c8e28dd..e2984bd 100644 --- a/hash.c +++ b/hash.c @@ -26,7 +26,7 @@ #include #include -void hash_buffer(struct mdfour *md, const char *s, size_t len) +void hash_buffer(struct mdfour *md, const void *s, size_t len) { mdfour_update(md, (unsigned char *)s, len); }