]> git.netwichtig.de Git - user/henk/code/inspircd.git/commitdiff
In this module we declare the md5 context as a class, then reference it in functions...
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>
Mon, 21 May 2007 19:28:51 +0000 (19:28 +0000)
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>
Mon, 21 May 2007 19:28:51 +0000 (19:28 +0000)
Not only does this make little sense readability wise, it triggers a warning in vs8. Fixed.

git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@7100 e03df62e-2008-0410-955e-edbf42e46eb7

src/modules/m_md5.cpp

index 43afbc15c9120c7400f5417ca4f955444b144181..ada92df8138894ce1955aff80e04876d19d2daf0 100644 (file)
@@ -64,7 +64,7 @@ class ModuleMD5 : public Module
                } while (--words);
        }
 
-       void MD5Init(struct MD5Context *ctx, unsigned int* key = NULL)
+       void MD5Init(MD5Context *ctx, unsigned int* key = NULL)
        {
                /* These are the defaults for md5 */
                if (!key)
@@ -86,7 +86,7 @@ class ModuleMD5 : public Module
                ctx->bytes[1] = 0;
        }
 
-       void MD5Update(struct MD5Context *ctx, byte const *buf, int len)
+       void MD5Update(MD5Context *ctx, byte const *buf, int len)
        {
                word32 t;
        
@@ -123,7 +123,7 @@ class ModuleMD5 : public Module
                memcpy(ctx->in, buf, len);
        }
        
-       void MD5Final(byte digest[16], struct MD5Context *ctx)
+       void MD5Final(byte digest[16], MD5Context *ctx)
        {
                int count = (int)(ctx->bytes[0] & 0x3f); /* Bytes in ctx->in */
                byte *p = (byte *)ctx->in + count;      /* First unused byte */