changeset 8386:143d0b29ba82

[gaim-migrate @ 9114] Fix a few compile warnings and errors when compiling with -ansi and run dos2unix on yahoo_auth.c and yahoo_auth.h committer: Tailor Script <tailor@pidgin.im>
author Mark Doliner <mark@kingant.net>
date Tue, 02 Mar 2004 08:05:03 +0000
parents 680aa8e0543e
children 98c9a35541ed
files src/conversation.c src/protocols/msn/nexus.h src/protocols/msn/switchboard.c src/protocols/napster/napster.c src/protocols/yahoo/yahoo_auth.c src/protocols/zephyr/zephyr.c
diffstat 6 files changed, 20 insertions(+), 16 deletions(-) [+]
line wrap: on
line diff
--- a/src/conversation.c	Tue Mar 02 07:41:05 2004 +0000
+++ b/src/conversation.c	Tue Mar 02 08:05:03 2004 +0000
@@ -65,23 +65,23 @@
 	if (*a == '@') {
 		if (*b != '@') return -1;
 
-		return strcasecmp(a + 1, b + 1);
+		return g_ascii_strcasecmp(a + 1, b + 1);
 
 	} else if (*a == '%') {
 		if (*b != '%') return -1;
 
-		return strcasecmp(a + 1, b + 1);
+		return g_ascii_strcasecmp(a + 1, b + 1);
 
 	} else if (*a == '+') {
 		if (*b == '@') return  1;
 		if (*b != '+') return -1;
 
-		return strcasecmp(a + 1, b + 1);
+		return g_ascii_strcasecmp(a + 1, b + 1);
 
 	} else if (*b == '@' || *b == '%' || *b == '+')
 		return 1;
 
-	return strcasecmp(a, b);
+	return g_ascii_strcasecmp(a, b);
 }
 
 static gboolean
--- a/src/protocols/msn/nexus.h	Tue Mar 02 07:41:05 2004 +0000
+++ b/src/protocols/msn/nexus.h	Tue Mar 02 08:05:03 2004 +0000
@@ -18,4 +18,4 @@
 MsnNexus *msn_nexus_new(MsnSession *session);
 void msn_nexus_destroy(MsnNexus *nexus);
 
-#endif // _MSN_NEXUS_H_
+#endif /* _MSN_NEXUS_H_ */
--- a/src/protocols/msn/switchboard.c	Tue Mar 02 07:41:05 2004 +0000
+++ b/src/protocols/msn/switchboard.c	Tue Mar 02 08:05:03 2004 +0000
@@ -646,7 +646,9 @@
 	char *buf;
 	size_t len;
 	int ret;
+#if 0
 	FILE *fp;
+#endif
 
 	g_return_val_if_fail(swboard != NULL, FALSE);
 	g_return_val_if_fail(msg     != NULL, FALSE);
--- a/src/protocols/napster/napster.c	Tue Mar 02 07:41:05 2004 +0000
+++ b/src/protocols/napster/napster.c	Tue Mar 02 08:05:03 2004 +0000
@@ -84,13 +84,13 @@
 
 	res = g_strsplit(message, " ", 2);
 
-	if (!strcasecmp(res[0], "/ME")) { /* MSG_CLIENT_PUBLIC */
+	if (!g_ascii_strcasecmp(res[0], "/ME")) { /* MSG_CLIENT_PUBLIC */
 		nap_write_packet(gc, 824, "%s \"%s\"", name, res[1]);
 
-	} else if (!strcasecmp(res[0], "/MSG")) { /* MSG_CLIENT_PUBLIC */
+	} else if (!g_ascii_strcasecmp(res[0], "/MSG")) { /* MSG_CLIENT_PUBLIC */
 		nap_write_packet(gc, 205, "%s", res[1]);
 
-	} else if (!strcasecmp(res[0], "/JOIN")) { /* join chatroom MSG_CLIENT_JOIN */
+	} else if (!g_ascii_strcasecmp(res[0], "/JOIN")) { /* join chatroom MSG_CLIENT_JOIN */
 		if (!res[1]) {
 			g_strfreev(res);
 			return 1;
@@ -100,19 +100,19 @@
 		else
 			nap_write_packet(gc, 400, "%s", res[1]);
 
-	} else if (!strcasecmp(res[0], "/PART")) { /* partchatroom MSG_CLIENT_PART */
+	} else if (!g_ascii_strcasecmp(res[0], "/PART")) { /* partchatroom MSG_CLIENT_PART */
 		nap_write_packet(gc, 401, "%s", res[1] ? res[1] : name);
 
-	} else if (!strcasecmp(res[0], "/TOPIC")) { /* set topic MSG_SERVER_TOPIC */
+	} else if (!g_ascii_strcasecmp(res[0], "/TOPIC")) { /* set topic MSG_SERVER_TOPIC */
 		nap_write_packet(gc, 410, "%s", res[1] ? res[1] : name);
 
-	} else if (!strcasecmp(res[0], "/WHOIS")) { /* whois request MSG_CLIENT_WHOIS */
+	} else if (!g_ascii_strcasecmp(res[0], "/WHOIS")) { /* whois request MSG_CLIENT_WHOIS */
 		nap_write_packet(gc, 603, "%s", res[1]);
 
-	} else if (!strcasecmp(res[0], "/PING")) { /* send ping MSG_CLIENT_PING */
+	} else if (!g_ascii_strcasecmp(res[0], "/PING")) { /* send ping MSG_CLIENT_PING */
 		nap_write_packet(gc, 751, "%s", res[1]);
 
-	} else if (!strcasecmp(res[0], "/KICK")) { /* kick asswipe MSG_CLIENT_KICK */
+	} else if (!g_ascii_strcasecmp(res[0], "/KICK")) { /* kick asswipe MSG_CLIENT_KICK */
 		nap_write_packet(gc, 829, "%s", res[1]);
 
 	} else {
--- a/src/protocols/yahoo/yahoo_auth.c	Tue Mar 02 07:41:05 2004 +0000
+++ b/src/protocols/yahoo/yahoo_auth.c	Tue Mar 02 08:05:03 2004 +0000
@@ -826,9 +826,9 @@
 
 	for (i = 0; i < 32; i++)
 	{
-		unsigned char	buffer = yahoo_auth_read45(initial, i);		// Find the location in the challenge to put the 1/0 bit
-		int				mask = ~(1 << buffer);						// so that we can do a replace of our current value.
-		int				new_value = (challenge >> i) & 1;			// Is this bit 1 or 0?
+		unsigned char	buffer = yahoo_auth_read45(initial, i);		/* Find the location in the challenge to put the 1/0 bit */
+		int				mask = ~(1 << buffer);						/* so that we can do a replace of our current value. */
+		int				new_value = (challenge >> i) & 1;			/* Is this bit 1 or 0? */
 
 		final_value = (final_value & mask) | (new_value << buffer);
 	}
--- a/src/protocols/zephyr/zephyr.c	Tue Mar 02 07:41:05 2004 +0000
+++ b/src/protocols/zephyr/zephyr.c	Tue Mar 02 08:05:03 2004 +0000
@@ -35,6 +35,8 @@
 
 #include "zephyr/zephyr.h"
 
+#include <strings.h>
+
 extern Code_t ZGetLocations(ZLocations_t *, int *);
 extern Code_t ZSetLocation(char *);
 extern Code_t ZUnsetLocation();