[Goodies-commits] r7532 - in xfce4-weather-plugin/trunk: . panel-plugin

Colin Leroy colin at xfce.org
Thu Jun 11 22:26:28 CEST 2009


Author: colin
Date: 2009-06-11 20:26:28 +0000 (Thu, 11 Jun 2009)
New Revision: 7532

Modified:
   xfce4-weather-plugin/trunk/ChangeLog
   xfce4-weather-plugin/trunk/panel-plugin/weather-http.c
Log:
2009-06-11	Colin Leroy <colin at colino.net>

	* panel-plugin/weather-http.c: Fix HTTP request (Host: and other
	parameters are only valid in HTTP/1.1)



Modified: xfce4-weather-plugin/trunk/ChangeLog
===================================================================
--- xfce4-weather-plugin/trunk/ChangeLog	2009-06-11 17:16:37 UTC (rev 7531)
+++ xfce4-weather-plugin/trunk/ChangeLog	2009-06-11 20:26:28 UTC (rev 7532)
@@ -1,5 +1,10 @@
 2009-06-11	Colin Leroy <colin at colino.net>
 
+	* panel-plugin/weather-http.c: Fix HTTP request (Host: and other
+	parameters are only valid in HTTP/1.1)
+
+2009-06-11	Colin Leroy <colin at colino.net>
+
 	* Fix bug #5444, "Make use of the new GtkTooltip API": 
 	Make the tooltip nicer when possible.
 

Modified: xfce4-weather-plugin/trunk/panel-plugin/weather-http.c
===================================================================
--- xfce4-weather-plugin/trunk/panel-plugin/weather-http.c	2009-06-11 17:16:37 UTC (rev 7531)
+++ xfce4-weather-plugin/trunk/panel-plugin/weather-http.c	2009-06-11 20:26:28 UTC (rev 7532)
@@ -217,7 +217,11 @@
   if (connection->proxy_host)
     request = g_strdup_printf ("GET http://%s%s HTTP/1.0\r\n\r\n", connection->hostname, connection->url);
   else
-    request = g_strdup_printf ("GET %s HTTP/1.0\r\nHost: %s\r\n\r\n", connection->url, connection->hostname);
+    request = g_strdup_printf ("GET %s HTTP/1.1\r\n"
+    				"Host: %s\r\n"
+				"Connection: close\r\n"
+				"\r\n", 
+				connection->url, connection->hostname);
 
   /* send the request */
   for (m = 0, n = strlen (request); m < n;)




More information about the Goodies-commits mailing list