Thu, 07 Nov 2013 01:51:26 +0100
HTTP: Fix a glib warning for improper HTTP response
| libpurple/http.c | file | annotate | diff | comparison | revisions |
--- a/libpurple/http.c Tue Nov 05 18:52:38 2013 +0100 +++ b/libpurple/http.c Thu Nov 07 01:51:26 2013 +0100 @@ -1117,9 +1117,10 @@ purple_http_conn_retry(hc); return FALSE; } else { - if (g_ascii_strcasecmp(purple_http_headers_get( - hc->response->headers, "Server"), - "YHttpServer") == 0) + const gchar *server = purple_http_headers_get( + hc->response->headers, "Server"); + if (server && + g_ascii_strcasecmp(server, "YHttpServer") == 0) { purple_debug_warning("http", "No more data " "while parsing headers (YHttpServer "