netclient ignores #set_redirect_mode method

Richard Jones <[email protected]> Thu, 23 Jun 2005 12:39:13 +0100
Newsgroups gmane.comp.lang.ocaml.lib.net.devel
Message-ID <[email protected]>
Http_client.message seems to ignore the #set_redirect_mode method.
Checking the code seems to prove this:

          match code with
            (301|302) ->
              (* Follow redirections for GET and HEAD requests *)
              begin
                let m = req # get_req_method() in
                if m = "GET" or m = "HEAD" then
                  try
                    let location = req # assoc_resp_header "location" in
                    req # init_query () location;
                    continue := true
                  with Not_found -> ()
              end

Unfortunately this is a show-stopper for us because we want to get at
some cookies sent in the original response (Netclient doesn't support
cookies either so we are having to implement cookies ourselves).

Rich.

-- 
Richard Jones, CTO Merjis Ltd.
Merjis - web marketing and technology - http://merjis.com
Team Notepad - intranets and extranets for business - http://team-notepad.com


-------------------------------------------------------
SF.Net email is sponsored by: Discover Easy Linux Migration Strategies
from IBM. Find simple to follow Roadmaps, straightforward articles,
informative Webcasts and more! Get everything you need to get up to
speed, fast. http://ads.osdn.com/?ad_id=7477&alloc_id=16492&op=click