]> git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - mdfour.c
Convert \ to / when loading texture from Q3 shader
[xonotic/darkplaces.git] / mdfour.c
index f647df2983a00d49b2525b86e4b02a48e82aa133..bfee0212acae3e88ab5216f3248e1b8f09c6bfbf 100644 (file)
--- a/mdfour.c
+++ b/mdfour.c
@@ -51,7 +51,7 @@
 #define ROUND3(a,b,c,d,k,s) a = lshift(a + H(b,c,d) + X[k] + 0x6ED9EBA1,s)
 
 /* this applies md4 to 64 byte chunks */
-static void mdfour64(struct mdfour *md, uint32 *M)
+static void mdfour64(struct mdfour_s *md, uint32 *M)
 {
        int j;
        uint32 AA, BB, CC, DD;
@@ -121,7 +121,7 @@ static void copy4(unsigned char *out,uint32 x)
        out[3] = (x>>24)&0xFF;
 }
 
-void mdfour_begin(struct mdfour *md)
+void mdfour_begin(struct mdfour_s *md)
 {
        md->A = 0x67452301;
        md->B = 0xefcdab89;
@@ -131,7 +131,7 @@ void mdfour_begin(struct mdfour *md)
 }
 
 
-static void mdfour_tail(struct mdfour *md, const unsigned char *in, int n)
+static void mdfour_tail(struct mdfour_s *md, const unsigned char *in, int n)
 {
        unsigned char buf[128];
        uint32 M[16];
@@ -158,7 +158,7 @@ static void mdfour_tail(struct mdfour *md, const unsigned char *in, int n)
        }
 }
 
-void mdfour_update(struct mdfour *md, const unsigned char *in, int n)
+void mdfour_update(struct mdfour_s *md, const unsigned char *in, int n)
 {
        uint32 M[16];
 
@@ -179,7 +179,7 @@ void mdfour_update(struct mdfour *md, const unsigned char *in, int n)
 }
 
 
-void mdfour_result(struct mdfour *md, unsigned char *out)
+void mdfour_result(struct mdfour_s *md, unsigned char *out)
 {
        copy4(out, md->A);
        copy4(out+4, md->B);
@@ -190,7 +190,7 @@ void mdfour_result(struct mdfour *md, unsigned char *out)
 
 void mdfour(unsigned char *out, const unsigned char *in, int n)
 {
-       struct mdfour md;
+       struct mdfour_s md;
        mdfour_begin(&md);
        mdfour_update(&md, in, n);
        mdfour_result(&md, out);