Mercurial > pidgin
diff libpurple/protocols/msn/httpconn.c @ 24388:7e8175f9b009
It should be more efficient to just use g_mallc() and then manually
null terminate the buffer, right?
| author | Mark Doliner <mark@kingant.net> |
|---|---|
| date | Wed, 12 Nov 2008 09:40:05 +0000 |
| parents | 3520b566ce25 |
| children | 9bdaf273c0ff |
line wrap: on
line diff
--- a/libpurple/protocols/msn/httpconn.c Wed Nov 12 09:32:10 2008 +0000 +++ b/libpurple/protocols/msn/httpconn.c Wed Nov 12 09:40:05 2008 +0000 @@ -157,8 +157,9 @@ } } - body = g_malloc0(body_len + 1); + body = g_malloc(body_len + 1); memcpy(body, body_start, body_len); + body[body_len] = '\0'; #ifdef MSN_DEBUG_HTTP purple_debug_misc("msn", "Incoming HTTP buffer (header): {%s\r\n}\n",
