Print

Print


@abh3 requested changes on this pull request.


In src/XrdHttp/XrdHttpReq.cc:

> @@ -661,6 +661,13 @@ bool XrdHttpReq::Redir(XrdXrootd::Bridge::Context &info, //!< the result context
   else
     redirdest = "Location: http://";
   
+  // port -1 signals redirect to local filesystem
+  // switch to file:// protocol
+  if (port == -1)

Ummm, I think the comment is wrong here. When port is < 0 then the target is a full URL not a host?token:port target. I presume you do set port to -1 and the target is a full URL with "file:://" as the protocol. But it might also be a regular full URL. The code here should take that into account and not merely assume it's a local file redirect. Technically, the check for '-1' is correct because it is documented as such. However, we are considering loosing it and allowing for any value less than zero to accommodate future needs. So, I'd suggest checking it's merely negative so we don't have to revisit this when it changes.


You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or unsubscribe.

[ { "@context": "http://schema.org", "@type": "EmailMessage", "potentialAction": { "@type": "ViewAction", "target": "https://github.com/xrootd/xrootd/pull/1242#pullrequestreview-444428656", "url": "https://github.com/xrootd/xrootd/pull/1242#pullrequestreview-444428656", "name": "View Pull Request" }, "description": "View this Pull Request on GitHub", "publisher": { "@type": "Organization", "name": "GitHub", "url": "https://github.com" } } ]

Use REPLY-ALL to reply to list

To unsubscribe from the XROOTD-DEV list, click the following link:
https://listserv.slac.stanford.edu/cgi-bin/wa?SUBED1=XROOTD-DEV&A=1