Fix redirects-to-different-hosts to not reuse the same connection
authorDan Winship <danw@gnome.org>
Sat, 12 Jun 2010 00:26:23 +0000 (20:26 -0400)
committerDan Winship <danw@gnome.org>
Sat, 12 Jun 2010 00:36:46 +0000 (20:36 -0400)
commit213d34a2b537a1df6298b466c8d300008cc28dea
tree5b1232949dec9a0f7c267dd6f430a49f103f3191
parent02752ac1958daa7ecf257762bc345cdf45569896
Fix redirects-to-different-hosts to not reuse the same connection

We were mistakenly reusing the same SoupConnection for a queue item
even if the message got redirected to a different host. Fix that. The
particular fix here (always force it to re-run
soup_session_get_connection() after a redirect) is a bit
over-aggressive, but this will get rewritten when we eventually fix
connection pooling in the proxy case.

Also, add a test to tests/redirect-test for this.
libsoup/soup-message-queue.c
tests/redirect-test.c