You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@hc.apache.org by "Oleg Kalnichevski (JIRA)" <ji...@apache.org> on 2007/02/13 19:38:05 UTC
[jira] Resolved: (HTTPCLIENT-632) Possible NPE in HttpHost
[ https://issues.apache.org/jira/browse/HTTPCLIENT-632?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Oleg Kalnichevski resolved HTTPCLIENT-632.
------------------------------------------
Resolution: Fixed
Fix Version/s: 3.1 Final
Protocol is checked for being not null at the construction time and remains immutable for the life time of the object. I removed the superfluous null check to keep Findbugs happy.
Oleg
> Possible NPE in HttpHost
> ------------------------
>
> Key: HTTPCLIENT-632
> URL: https://issues.apache.org/jira/browse/HTTPCLIENT-632
> Project: HttpComponents HttpClient
> Issue Type: Bug
> Components: HttpClient
> Affects Versions: 3.1 Beta 1
> Reporter: Sebb
> Priority: Minor
> Fix For: 3.1 Final
>
>
> HttpHost line 167 says:
> if (this.port != this.protocol.getDefaultPort()) {
> However, a few lines above, protocol is checked for null.
> Line 167 should probably read:
> if (this.protocol != null && this.port != this.protocol.getDefaultPort()) {
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
To unsubscribe, e-mail: httpcomponents-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: httpcomponents-dev-help@jakarta.apache.org