diff src/protocols/qq/char_conv.c @ 14058:32a71e64ceae

[gaim-migrate @ 16673] Eliminated a number of warnings. Generally, this consisted of fixing incorrectly declared data types and adding a few casts. I also moved some declarations that occurred in the middle of code. Minor formatting changes. committer: Tailor Script <tailor@pidgin.im>
author Mark Huetsch <markhuetsch>
date Tue, 08 Aug 2006 23:20:08 +0000
parents 3cefea0bf4a2
children
line wrap: on
line diff
--- a/src/protocols/qq/char_conv.c	Tue Aug 08 01:12:58 2006 +0000
+++ b/src/protocols/qq/char_conv.c	Tue Aug 08 23:20:08 2006 +0000
@@ -114,7 +114,8 @@
 	else {			/* conversion error */
 		gaim_debug(GAIM_DEBUG_ERROR, "QQ", "%s\n", error->message);
 		gaim_debug(GAIM_DEBUG_WARNING, "QQ",
-			   "Dump failed text\n%s", hex_dump_to_str(str, (len == -1) ? strlen(str) : len));
+			   "Dump failed text\n%s", 
+			   hex_dump_to_str((guint8 *) str, (len == -1) ? strlen(str) : len));
 		g_error_free(error);
 		return g_strdup(QQ_NULL_MSG);
 	}
@@ -130,7 +131,7 @@
 	g_return_val_if_fail(data != NULL && from_charset != NULL, -1);
 
 	len = data[0];
-	*ret = _my_convert(data + 1, (gssize) len, UTF8, from_charset);
+	*ret = _my_convert((gchar *) (data + 1), (gssize) len, UTF8, from_charset);
 
 	return len + 1;
 }
@@ -154,7 +155,7 @@
 	read_packet_b(data, &cursor, len, &bar);	/* skip, not sure of its use */
 	read_packet_w(data, &cursor, len, &charset_code);
 
-	font_name = g_strndup(cursor, data + len - cursor);
+	font_name = g_strndup((gchar *) cursor, data + len - cursor);
 
 	font_size = _get_size(font_attr);
 	is_bold = _check_bold(font_attr);
@@ -223,7 +224,7 @@
 	GString *converted;
 
 	converted = g_string_new("");
-	segments = split_data(text, strlen(text), "\x14", 0);
+	segments = split_data((guint8 *) text, strlen(text), "\x14", 0);
 	g_string_append(converted, segments[0]);
 
 	while ((*(++segments)) != NULL) {