fix warnings by adding type casts
authorvortex <vortex@d7cf8633-e32d-0410-b094-e92efae38249>
Thu, 25 Nov 2010 19:23:41 +0000 (19:23 +0000)
committervortex <vortex@d7cf8633-e32d-0410-b094-e92efae38249>
Thu, 25 Nov 2010 19:23:41 +0000 (19:23 +0000)
git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@10630 d7cf8633-e32d-0410-b094-e92efae38249

crypto.c
prvm_cmds.c

index 7511169..fa2ea67 100644 (file)
--- a/crypto.c
+++ b/crypto.c
@@ -2367,7 +2367,7 @@ size_t Crypto_SignData(const void *data, size_t datasize, int keyid, void *signe
                return 0;
        if(!pubkeys_havepriv[keyid])
                return 0;
-       if(qd0_blind_id_sign_with_private_id_sign(pubkeys[keyid], true, false, data, datasize, signed_data, &signed_size))
+       if(qd0_blind_id_sign_with_private_id_sign(pubkeys[keyid], true, false, (char *)data, datasize, (char *)signed_data, &signed_size))
                return signed_size;
        return 0;
 }
index d89214c..ba95578 100644 (file)
@@ -5895,7 +5895,7 @@ void VM_uri_get (void)
                                if(stringbuffer->strings[i])
                                        ltotal += strlen(stringbuffer->strings[i]);
                        }
-                       handle->postdata = Z_Malloc(ltotal);
+                       handle->postdata = (unsigned char *)Z_Malloc(ltotal);
                        handle->postlen = ltotal;
                        ltotal = 0;
                        for(i = 0;i < stringbuffer->num_strings;i++)
@@ -5916,13 +5916,13 @@ void VM_uri_get (void)
                }
                else
                {
-                       handle->postdata = Z_Malloc(l);
+                       handle->postdata = (unsigned char *)Z_Malloc(l);
                        handle->postlen = l;
                        memcpy(handle->postdata, postseparator, l);
                }
                if(postkeyid >= 0)
                {
-                       unsigned char *signed_data = Z_Malloc(handle->postlen + 8192);
+                       unsigned char *signed_data = (unsigned char *)Z_Malloc(handle->postlen + 8192);
                        size_t signed_size = Crypto_SignData(handle->postdata, handle->postlen, postkeyid, signed_data, handle->postlen + 8192);
                        if(!signed_size)
                        {