diff options
Diffstat (limited to 'protocols/oscar')
-rw-r--r-- | protocols/oscar/oscar.c | 3 | ||||
-rw-r--r-- | protocols/oscar/rxqueue.c | 9 | ||||
-rw-r--r-- | protocols/oscar/service.c | 2 |
3 files changed, 10 insertions, 4 deletions
diff --git a/protocols/oscar/oscar.c b/protocols/oscar/oscar.c index 5f19f12b..4e552bce 100644 --- a/protocols/oscar/oscar.c +++ b/protocols/oscar/oscar.c @@ -20,7 +20,6 @@ * */ -#include "sock.h" #include <errno.h> #include <ctype.h> #include <string.h> @@ -32,6 +31,7 @@ #include "nogaim.h" #include "bitlbee.h" #include "proxy.h" +#include "sock.h" #include "aim.h" #include "icq.h" @@ -607,6 +607,7 @@ static void damn_you(gpointer data, gint source, GaimInputCondition c) g_free(pos); return; } + /* [WvG] Wheeeee! Who needs error checking anyway? ;-) */ read(pos->fd, m, 16); m[16] = '\0'; gaim_input_remove(pos->inpa); diff --git a/protocols/oscar/rxqueue.c b/protocols/oscar/rxqueue.c index d8adaa73..6e8dd29c 100644 --- a/protocols/oscar/rxqueue.c +++ b/protocols/oscar/rxqueue.c @@ -352,8 +352,15 @@ int aim_get_command(aim_session_t *sess, aim_conn_t *conn) if (conn->fd == -1) return -1; /* its a aim_conn_close()'d connection */ - if (conn->fd < 3) /* can happen when people abuse the interface */ + /* KIDS, THIS IS WHAT HAPPENS IF YOU USE CODE WRITTEN FOR GUIS IN A DAEMON! + + And wouldn't it make sense to return something that prevents this function + from being called again IMMEDIATELY (and making the program suck up all + CPU time)?... + + if (conn->fd < 3) return 0; + */ if (conn->status & AIM_CONN_STATUS_INPROGRESS) return aim_conn_completeconnect(sess, conn); diff --git a/protocols/oscar/service.c b/protocols/oscar/service.c index 875a2eb0..573e1983 100644 --- a/protocols/oscar/service.c +++ b/protocols/oscar/service.c @@ -736,8 +736,6 @@ int aim_setextstatus(aim_session_t *sess, aim_conn_t *conn, guint32 status) tlvlen = aim_addtlvtochain32(&tl, 0x0006, data); - printf("%d\n", tlvlen); - if (!(fr = aim_tx_new(sess, conn, AIM_FRAMETYPE_FLAP, 0x02, 10 + 8))) return -ENOMEM; |