From 7bdd10be8ff88baba813e984eccc7cf934961ad7 Mon Sep 17 00:00:00 2001 From: vortex Date: Thu, 25 Nov 2010 19:23:41 +0000 Subject: [PATCH] fix warnings by adding type casts git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@10630 d7cf8633-e32d-0410-b094-e92efae38249 --- crypto.c | 2 +- prvm_cmds.c | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/crypto.c b/crypto.c index 75111696..fa2ea67c 100644 --- 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; } diff --git a/prvm_cmds.c b/prvm_cmds.c index d89214c1..ba955780 100644 --- a/prvm_cmds.c +++ b/prvm_cmds.c @@ -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) { -- 2.39.2