summaryrefslogtreecommitdiff
path: root/src/login/md5calc.c
diff options
context:
space:
mode:
author(no author) <(no author)@54d463be-8e91-2dee-dedb-b68131a5f0ec>2005-01-24 03:12:42 +0000
committer(no author) <(no author)@54d463be-8e91-2dee-dedb-b68131a5f0ec>2005-01-24 03:12:42 +0000
commit817a048b554ed05fda836a9b55e0dc9a816334b7 (patch)
tree1ff6297e35e9c286198b0e5201f186d4cdb9f4c5 /src/login/md5calc.c
parentb50b9537644c77a4a9e03e5ad0e8d7ee3a952401 (diff)
downloadhercules-817a048b554ed05fda836a9b55e0dc9a816334b7.tar.gz
hercules-817a048b554ed05fda836a9b55e0dc9a816334b7.tar.bz2
hercules-817a048b554ed05fda836a9b55e0dc9a816334b7.tar.xz
hercules-817a048b554ed05fda836a9b55e0dc9a816334b7.zip
A lot of changes. login and char server compile under both TXT and SQL under g++. Same for the convertors (login and char). One change that I felt iffy about, but it worked, was the char* buf -> unsinged char* bug in clif.c
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/branches/stable@975 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/login/md5calc.c')
-rw-r--r--src/login/md5calc.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/login/md5calc.c b/src/login/md5calc.c
index 96bfc34d0..0ee64476d 100644
--- a/src/login/md5calc.c
+++ b/src/login/md5calc.c
@@ -96,7 +96,7 @@ static void MD5_Round_Calculate(const unsigned char *block,
//Save A as AA, B as BB, C as CC, and and D as DD (saving of A, B, C, and D)
unsigned int A=*A2, B=*B2, C=*C2, D=*D2;
unsigned int AA = A,BB = B,CC = C,DD = D;
-
+
//It is a large region variable reluctantly because of calculation of a round. . . for Round1...4
pX = X;
@@ -187,7 +187,7 @@ void MD5_String2binary(const char * string, char * output)
memset(padding_message+copy_len, 0, 64 - copy_len); //It buries by 0 until it becomes extended bit length.
padding_message[copy_len] |= 0x80; //The next of a message is 1.
- //1-4
+ //1-4
//If 56 bytes or more (less than 64 bytes) of remainder becomes, it will calculate by extending to 64 bytes.
if (56 <= copy_len) {
MD5_Round_Calculate(padding_message, A,B,C,D);
@@ -226,7 +226,7 @@ void MD5_String(const char * string, char * output)
{
unsigned char digest[16];
- MD5_String2binary(string,digest);
+ MD5_String2binary(string,(char*)digest);
sprintf(output,
"%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x%02x",
digest[ 0], digest[ 1], digest[ 2], digest[ 3],