diff src/protocols/oscar/rxqueue.c @ 5927:04dc7fe68889

[gaim-migrate @ 6367] Another crisp patch from Ryan McCabe (odin). This one makes libfaim act less sucky in the event of some weird connection problems (read: rare shizzle). Also some header and compile warning cleanup. committer: Tailor Script <tailor@pidgin.im>
author Mark Doliner <mark@kingant.net>
date Fri, 20 Jun 2003 04:16:23 +0000
parents 2d9f7d2e3558
children c86f075b269a
line wrap: on
line diff
--- a/src/protocols/oscar/rxqueue.c	Fri Jun 20 03:55:56 2003 +0000
+++ b/src/protocols/oscar/rxqueue.c	Fri Jun 20 04:16:23 2003 +0000
@@ -182,9 +182,16 @@
 	 * Rendezvous (client to client) connections do not speak FLAP, so this 
 	 * function will break on them.
 	 */
-	if (conn->type == AIM_CONN_TYPE_RENDEZVOUS)
-		payloadlen = aim_get_command_rendezvous(sess, conn, newrx);
-	else if (conn->type == AIM_CONN_TYPE_LISTENER) {
+	if (conn->type == AIM_CONN_TYPE_RENDEZVOUS) {
+		int ret = aim_get_command_rendezvous(sess, conn, newrx);
+
+		if (ret < 0) {
+			free(newrx);
+			return -1;
+		}
+
+		payloadlen = ret;
+	} else if (conn->type == AIM_CONN_TYPE_LISTENER) {
 		faimdprintf(sess, 0, "AIM_CONN_TYPE_LISTENER on fd %d\n", conn->fd);
 		free(newrx);
 		return -1;