gaurachit
Channel Surfer
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-12-2014
07:43 AM
Re: Problem with HTTP redirect 302 and HLS
Hi Joel,
Thanks for quick reply. I tried the method which you have suggested but no luck.
I am not able to get the header data means
h = msg.GetResponseHeaders()
Print h
this is returning blank.
As sdkdocs said:
GetResponseHeaders() as Object
Returns an roAssociativeArray containing all the headers returned by the server for appropriate protocols (such as HTTP).
Headers are only returned when the status code is greater than or equal to 200 and less than 300.
The response code which I am getting is "-3" and that's why I am not able to get the header data.
but when I am trying the API directly on browser its giving me the XML.
Is there any other way to work with this
Thanks for quick reply. I tried the method which you have suggested but no luck.
I am not able to get the header data means
h = msg.GetResponseHeaders()
Print h
this is returning blank.
As sdkdocs said:
GetResponseHeaders() as Object
Returns an roAssociativeArray containing all the headers returned by the server for appropriate protocols (such as HTTP).
Headers are only returned when the status code is greater than or equal to 200 and less than 300.
The response code which I am getting is "-3" and that's why I am not able to get the header data.
but when I am trying the API directly on browser its giving me the XML.
Is there any other way to work with this

RokuJoel
Binge Watcher
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-15-2014
11:43 AM
Re: Problem with HTTP redirect 302 and HLS
I wonder if ifURLTransfer.retainBodyOnError would help, and also, have you tried the GetResponseHeadersArray method of roUrlEvent?
- Joel
- Joel

RokuMarkn
Visitor
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-15-2014
11:53 AM
Re: Problem with HTTP redirect 302 and HLS
-3 is not an http status code of course, since all status codes are positive 3-digit integers. If you're getting this -3 value from roUrlEvent.GetResponseCode, the doc (http://sdkdocs.roku.com/display/sdkdoc/roUrlEvent) says that that value means CURLE_URL_MALFORMAT. So it sounds like your URL is invalid.
Also, this doesn't have anything to do with the original topic (redirects and HLS), does it? And Roku does support redirects internally. I'm not sure if it did at the time the original post was posted, over 3 years ago, which demonstrates the reason it's not a good idea to post to very old threads.
--Mark
Also, this doesn't have anything to do with the original topic (redirects and HLS), does it? And Roku does support redirects internally. I'm not sure if it did at the time the original post was posted, over 3 years ago, which demonstrates the reason it's not a good idea to post to very old threads.
--Mark
- « Previous
-
- 1
- 2
- Next »