diff options
author | Jeff Connelly <jeff2@soc.pidgin.im> | 2008-01-27 04:26:38 +0000 |
---|---|---|
committer | Jeff Connelly <jeff2@soc.pidgin.im> | 2008-01-27 04:26:38 +0000 |
commit | ffc19b3d3646304f0481234b361edfb91a07e1d0 (patch) | |
tree | 25f53a29cf0e5c40c2d96b89653764cf242d23d7 /libpurple/protocols/myspace/session.c | |
parent | f277c73a7e516410cce590fd09933924d4c0bcec (diff) | |
download | pidgin-ffc19b3d3646304f0481234b361edfb91a07e1d0.tar.gz |
In msimprpl, grow the read buffer if it gets full using g_realloc(), similar to
how the IRC prpl does it. Now large messages should be received and processed
without filling up the read buffer and crashing.
Diffstat (limited to 'libpurple/protocols/myspace/session.c')
-rw-r--r-- | libpurple/protocols/myspace/session.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/libpurple/protocols/myspace/session.c b/libpurple/protocols/myspace/session.c index 92a5e94da8..1146d06bb2 100644 --- a/libpurple/protocols/myspace/session.c +++ b/libpurple/protocols/myspace/session.c @@ -59,7 +59,8 @@ msim_session_new(PurpleAccount *acct) session->server_info = NULL; session->rxoff = 0; - session->rxbuf = g_new0(gchar, MSIM_READ_BUF_SIZE); + session->rxsize = MSIM_READ_BUF_SIZE; + session->rxbuf = g_new0(gchar, session->rxsize); session->next_rid = 1; session->last_comm = time(NULL); session->inbox_status = 0; |