diff --git a/md5.c b/md5.c index 781dbd1..3f8ad28 100644 --- a/md5.c +++ b/md5.c @@ -308,7 +308,7 @@ void md5_end(void *resbuf, md5_ctx_t *ctx) memset(ctx, 0, sizeof(*ctx)); } -int md5sum(char *file, void *md5_buf) +int md5sum(const char *file, void *md5_buf) { char buf[256]; md5_ctx_t ctx; diff --git a/md5.h b/md5.h index b2f1b80..d3ee4e3 100644 --- a/md5.h +++ b/md5.h @@ -53,6 +53,6 @@ typedef struct md5_ctx { extern void md5_begin(md5_ctx_t *ctx); extern void md5_hash(const void *data, size_t length, md5_ctx_t *ctx); extern void md5_end(void *resbuf, md5_ctx_t *ctx); -int md5sum(char *file, void *md5_buf); +int md5sum(const char *file, void *md5_buf); #endif