/soc/2012/sanket/statscollector-2.x.y: 55abbe748668: [BUGFIX] ro...

Sanket Agarwal sanket at soc.pidgin.im
Mon Aug 27 15:24:48 EDT 2012


Changeset: 55abbe74866826d3890dc61378a1d81fb51b00e2
Author:	 Sanket Agarwal <sanket at soc.pidgin.im>
Date:	 2012-08-27 12:23 +0530
Branch:	 soc.2012.statscollector
URL: http://hg.pidgin.im/soc/2012/sanket/statscollector-2.x.y/rev/55abbe748668

Description:

[BUGFIX] rock does not like host:port type of request

diffstat:

 libpurple/plugins/statscollector.c |  8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diffs (27 lines):

diff --git a/libpurple/plugins/statscollector.c b/libpurple/plugins/statscollector.c
--- a/libpurple/plugins/statscollector.c
+++ b/libpurple/plugins/statscollector.c
@@ -263,8 +263,8 @@ refresh_public_server_cache(gpointer dat
   request = g_strdup_printf(\
           "GET /%s HTTP/1.0\r\n"
           "Connection: keep-alive\r\n"
-          "Host: %s:%d\r\n\r\n",
-          path, host, port);
+          "Host: %s\r\n\r\n",
+          path, host);
   purple_debug_info("STATS", "%s", request);
   purple_util_fetch_url_request(url, TRUE, NULL, FALSE, request, TRUE, refresh_public_server_cache_cb, send_success);
 
@@ -946,10 +946,10 @@ send_stats()
   request = g_strdup_printf(\
           "POST /%s HTTP/1.0\r\n"
           "Connection: keep-alive\r\n"
-          "Host: %s:%d\r\n"
+          "Host: %s\r\n"
           "Content-Type: application/x-www-form-urlencoded; charset=UTF-8\r\n"
           "Content-Length: %" G_GSIZE_FORMAT "\r\n\r\n%s",
-          path, host, port, strlen(postdata), postdata);
+          path, host, strlen(postdata), postdata);
 
 #if PURPLE_VERSION_CHECK(3,0,0)
   urldata = purple_util_fetch_url_request(NULL, url, TRUE, NULL, FALSE, request, FALSE, -1, url_callback, send_success);



More information about the Commits mailing list