]> git.sesse.net Git - vlc/blobdiff - src/misc/md5.c
The include vlc_md5.h is in the include path and not local
[vlc] / src / misc / md5.c
index 75a698f5518873cb8e838cec9401942054e85e8e..48d817f857979bf00285a21c80a4af3529565dd5 100644 (file)
@@ -1,8 +1,8 @@
 /*****************************************************************************
  * md5.c: not so strong MD5 hashing
  *****************************************************************************
- * Copyright (C) 2004-2005 VideoLAN
- * $Id: drms.c 10101 2005-03-02 16:47:31Z robux4 $
+ * Copyright (C) 2004-2005 the VideoLAN team
+ * $Id$
  *
  * Authors: Jon Lech Johansen <jon-vl@nanocrew.net>
  *          Sam Hocevar <sam@zoy.org>
@@ -24,7 +24,7 @@
 
 #include <string.h>
 #include <vlc/vlc.h>
-#include "vlc_md5.h"
+#include <vlc_md5.h>
 
 #ifdef WORDS_BIGENDIAN
 /*****************************************************************************
@@ -53,9 +53,9 @@ static inline void Reverse( uint32_t *p_buffer, int n )
     ( w += f(x, y, z) + data,  w = w<<s | w>>(32-s),  w += x )
 
 /*****************************************************************************
- * Digest: update the MD5 digest with 64 bytes of data
+ * DigestMD5: update the MD5 digest with 64 bytes of data
  *****************************************************************************/
-void Digest( struct md5_s *p_md5, uint32_t *p_input )
+void DigestMD5( struct md5_s *p_md5, uint32_t *p_input )
 {
     uint32_t a, b, c, d;
 
@@ -174,7 +174,7 @@ void AddMD5( struct md5_s *p_md5, const uint8_t *p_src, uint32_t i_len )
     {
         memcpy( ((uint8_t *)p_md5->p_data) + i_current, p_src,
                 (64 - i_current) );
-        Digest( p_md5, p_md5->p_data );
+        DigestMD5( p_md5, p_md5->p_data );
 
         i_offset += (64 - i_current);
         i_len -= (64 - i_current);
@@ -186,7 +186,7 @@ void AddMD5( struct md5_s *p_md5, const uint8_t *p_src, uint32_t i_len )
     {
         uint32_t p_tmp[ 16 ];
         memcpy( p_tmp, p_src + i_offset, 64 );
-        Digest( p_md5, p_tmp );
+        DigestMD5( p_md5, p_tmp );
         i_offset += 64;
         i_len -= 64;
     }
@@ -217,7 +217,7 @@ void EndMD5( struct md5_s *p_md5 )
     if( i_current > 56 )
     {
         memset( ((uint8_t *)p_md5->p_data) + i_current, 0, (64 - i_current) );
-        Digest( p_md5, p_md5->p_data );
+        DigestMD5( p_md5, p_md5->p_data );
         i_current = 0;
     }
 
@@ -228,7 +228,7 @@ void EndMD5( struct md5_s *p_md5 )
     p_md5->p_data[ 15 ] = (p_md5->i_bits >> 32);
     REVERSE( &p_md5->p_data[ 14 ], 2 );
 
-    Digest( p_md5, p_md5->p_data );
+    DigestMD5( p_md5, p_md5->p_data );
 }