changeset 11586:03cd74ca2562

[gaim-migrate @ 13856] clean up some compile warnings committer: Tailor Script <tailor@pidgin.im>
author Nathan Walp <nwalp@pidgin.im>
date Sun, 02 Oct 2005 16:50:08 +0000
parents 46265a317bd3
children e8585a330636
files src/gtkimhtml.c src/ntlm.c src/protocols/sametime/meanwhile/srvc_store.c src/protocols/silc/buddy.c src/status.c src/upnp.c
diffstat 6 files changed, 16 insertions(+), 11 deletions(-) [+]
line wrap: on
line diff
--- a/src/gtkimhtml.c	Sun Oct 02 05:58:51 2005 +0000
+++ b/src/gtkimhtml.c	Sun Oct 02 16:50:08 2005 +0000
@@ -841,7 +841,7 @@
 
 /* Convert from UCS-2 to UTF-8, stripping the BOM if one is present.*/
 static gchar *
-ucs2_to_utf8_with_bom_check(guchar *data, guint len) {
+ucs2_to_utf8_with_bom_check(gchar *data, guint len) {
 	char *fromcode = NULL;
 	GError *error = NULL;
 	guint16 c;
--- a/src/ntlm.c	Sun Oct 02 05:58:51 2005 +0000
+++ b/src/ntlm.c	Sun Oct 02 16:50:08 2005 +0000
@@ -131,7 +131,7 @@
 }
 
 gchar *gaim_ntlm_parse_type2(gchar *type2) {
-	guint retlen;
+	gsize retlen;
 	static gchar nonce[8];
 	struct type2_message *tmsg = (struct type2_message*)gaim_base64_decode((char*)type2, &retlen);
 	memcpy(nonce, tmsg->nonce, 8);
@@ -157,7 +157,7 @@
 static void des_ecb_encrypt(char *plaintext, char *result, char *key) {
 	GaimCipher *cipher;
 	GaimCipherContext *context;
-	guint outlen;
+	gsize outlen;
 	
 	cipher = gaim_ciphers_find_cipher("des");
 	context = gaim_cipher_context_new(cipher, NULL);
--- a/src/protocols/sametime/meanwhile/srvc_store.c	Sun Oct 02 05:58:51 2005 +0000
+++ b/src/protocols/sametime/meanwhile/srvc_store.c	Sun Oct 02 16:50:08 2005 +0000
@@ -167,7 +167,7 @@
 
   struct mwStorageUnit *item = req->item;
 
-  g_message("storage request %s: key = 0x%x, result = 0x%x, length = %u",
+  g_message("storage request %s: key = 0x%x, result = 0x%x, length = %" G_GSIZE_FORMAT,
 	    action_str(req->action),
 	    item->key, req->result_code, item->data.len);
   
--- a/src/protocols/silc/buddy.c	Sun Oct 02 05:58:51 2005 +0000
+++ b/src/protocols/silc/buddy.c	Sun Oct 02 16:50:08 2005 +0000
@@ -92,14 +92,19 @@
 								NULL, NULL, key, a->responder);
 			silc_ske_free_key_material(key);
 
+			
 			/* Open IM window */
 			convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM,
 									client_entry->nickname, sg->account);
-			if (convo)
+			if (convo) {
+				/* we don't have windows in the core anymore...but we may want to
+				 * provide some method for asking the UI to show the window
 				gaim_conv_window_show(gaim_conversation_get_window(convo));
-			else
+				 */
+			} else {
 				convo = gaim_conversation_new(GAIM_CONV_TYPE_IM, sg->account,
 							      client_entry->nickname);
+			}
 			g_snprintf(tmp, sizeof(tmp), "%s [private key]", client_entry->nickname);
 			gaim_conversation_set_title(convo, tmp);
 		}
--- a/src/status.c	Sun Oct 02 05:58:51 2005 +0000
+++ b/src/status.c	Sun Oct 02 16:50:08 2005 +0000
@@ -826,7 +826,7 @@
 		}
 		else if (value->type == GAIM_TYPE_INT)
 		{
-			int int_data = (int)attrs->data;
+			int int_data = GPOINTER_TO_INT(attrs->data);
 			attrs = attrs->next;
 			if (int_data == value->data.int_data)
 				continue;
@@ -835,7 +835,7 @@
 		}
 		else if (value->type == GAIM_TYPE_BOOLEAN)
 		{
-			gboolean boolean_data = (gboolean)attrs->data;
+			gboolean boolean_data = GPOINTER_TO_INT(attrs->data);
 			attrs = attrs->next;
 			if (boolean_data == value->data.boolean_data)
 				continue;
--- a/src/upnp.c	Sun Oct 02 05:58:51 2005 +0000
+++ b/src/upnp.c	Sun Oct 02 16:50:08 2005 +0000
@@ -95,7 +95,7 @@
                            "\"urn:schemas-upnp-org:"                       \
                            "service:%s#%s\"\r\n"                           \
                            "CONTENT-TYPE: text/xml ; charset=\"utf-8\"\r\n"\
-                           "Content-Length: %i\r\n\r\n"
+                           "Content-Length: %zi\r\n\r\n"
 
 #define SOAP_ACTION  "<?xml version=\"1.0\" encoding=\"utf-8\"?>\r\n"     \
                      "<s:Envelope xmlns:s="                               \
@@ -205,13 +205,13 @@
                     gint sock,
                     GaimInputCondition cond)
 {
-  int sizeSent, totalSizeSent = 0;
+  gsize sizeSent, totalSizeSent = 0;
   extern int errno;
   NetResponseData* nrd = data;
 
   gaim_timeout_remove(nrd->tima);
   while(totalSizeSent < strlen(nrd->sendBuffer)) {
-    sizeSent = send(sock,(gchar*)((int)nrd->sendBuffer+totalSizeSent),
+    sizeSent = send(sock,(gchar*)(nrd->sendBuffer+totalSizeSent),
                       strlen(nrd->sendBuffer)-totalSizeSent,0);
     if(sizeSent <= 0 && errno != EINTR) {
       gaim_debug_error("upnp",