gaim/gaim

92944d620134
Parents d23d5e6c93c9
Children 3e4228dc5f77
Fix receiving files on Yahoo with proxies that interfere with http headers
--- a/src/protocols/yahoo/yahoo_filexfer.c Sun Feb 06 10:19:08 2005 -0500
+++ b/src/protocols/yahoo/yahoo_filexfer.c Sun Feb 06 12:40:26 2005 -0500
@@ -261,6 +261,11 @@
xd->rxlen += len;
length = g_strstr_len(xd->rxqueue, len, "Content-length:");
+ /* some proxies re-write this header, changing the capitalization :(
+ * technically that's allowed since headers are case-insensitive
+ * [RFC 2616, section 4.2] */
+ if (length == NULL)
+ length = g_strstr_len(xd->rxqueue, len, "Content-Length:");
if (length) {
end = g_strstr_len(length, length - xd->rxqueue, "\r\n");
if (!end)