RE: Open more than one HTTP request to a host?

Richard Atterer wrote:
> 
> As always with libwww, it's probably possible to play some 
> dirty tricks to
> get around the limitation. For this, you somehow need to fool 
> HTHost_new()
> into creating another host object. For example, it might be 
> possible just
> to append "." to the hostname for a second connection.

Thank you, but surely it can't be this easy? :)

In HTHost_new, there's a 'while' loop labelled "Search the cache".
Remove this loop, and the existing host is never found, so a new one is
returned every time.  Problem solved, assuming you never want to
pipeline HTTP requests.  The only other catch I can see so far is that
HTHost_find will then be useless and/or unpredictable, but AFAICT this
function is never actually called, at least not from within libwww.

Dirty trick?  Yes, I think so.  I haven't tried FTP with it yet
either...

Regards,

Tim Serong
-- 
tim.serong@conceiva.com
http://www.conceiva.com

Received on Tuesday, 4 March 2003 20:21:06 UTC