diff options
-rw-r--r-- | common/md5.cpp | 4 | ||||
-rw-r--r-- | common/md5.h | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/common/md5.cpp b/common/md5.cpp index 52af84b3c7..55b2aef79a 100644 --- a/common/md5.cpp +++ b/common/md5.cpp @@ -239,14 +239,14 @@ void md5_finish( md5_context *ctx, uint8 digest[16] ) PUT_UINT32( ctx->state[3], digest, 12 ); } -bool md5_file( const char *name, uint8 digest[16] ) +bool md5_file( const char *name, uint8 digest[16], const char *directory ) { File f; md5_context ctx; int i; unsigned char buf[1000]; - f.open(name); + f.open(name, File::kFileReadMode, directory); if( ! f.isOpen() ) { warning( "md5_file couldn't open '%s'", name ); diff --git a/common/md5.h b/common/md5.h index 045e821f80..fe83ebda84 100644 --- a/common/md5.h +++ b/common/md5.h @@ -35,6 +35,6 @@ void md5_starts( md5_context *ctx ); void md5_update( md5_context *ctx, const uint8 *input, uint32 length ); void md5_finish( md5_context *ctx, uint8 digest[16] ); -bool md5_file( const char *name, uint8 digest[16] ); +bool md5_file( const char *name, uint8 digest[16], const char *directory = NULL ); #endif |