Details
-
Bug
-
Status: Closed
-
Minor
-
Resolution: Duplicate
-
1.5
-
None
-
None
Description
In the getReader(String) method of org.apache.jetspeed.portal.portlets.WebBrowserPortlet class, the encoding is obtained by calling the getContentEncoding() on the URLConnection object.
Subsequently the Authorization request header is set by calling setRequestProperty which causes IllegalStateException of "Already connected".
Apparently, once the method getContentEncoding() is called a connection is already established which throws this exception.
The fix would be to call the getContentEncoding() method after setting the required request headers.