--- a/libpurple/http.c Thu Jan 21 21:12:51 2016 +1300 +++ b/libpurple/http.c Tue Feb 09 05:40:48 2016 +0000 @@ -1190,6 +1190,10 @@ const gchar *redirect; if (hc->is_chunked && !hc->chunks_done) { + if (len == 0) { + _purple_http_error(hc, _("Chunked connection terminated")); + return FALSE; + } if (purple_debug_is_verbose()) { purple_debug_misc("http", "I need the terminating empty chunk\n");