hc-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "jason mathews (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (HTTPCLIENT-1433) DefaultClientConnectionOperator instance check inconsistent with explicit cast
Date Fri, 08 Nov 2013 16:35:17 GMT

     [ https://issues.apache.org/jira/browse/HTTPCLIENT-1433?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

jason mathews updated HTTPCLIENT-1433:
--------------------------------------

    Description: 
Class checks for LayeredConnectionSocketFactory instance then casts to SchemeLayeredSocketFactory
at line 214.

Assertion check needs to be for SchemeLayeredSocketFactory not  LayeredConnectionSocketFactory
in DefaultClientConnectionOperator.updateSecureConnection().

{code:java}
package org.apache.http.impl.conn;
class DefaultClientConnectionOperator
  updateSecureConnection()  {
...
// line 214
        Asserts.check(schm.getSchemeSocketFactory() instanceof LayeredConnectionSocketFactory,
            "Socket factory must implement SchemeLayeredSocketFactory");
        final SchemeLayeredSocketFactory lsf = (SchemeLayeredSocketFactory) schm.getSchemeSocketFactory();
  }
{code}

  was:
Class checks for LayeredConnectionSocketFactory instance then casts to SchemeLayeredSocketFactory
at line 214.

Assertion check needs to be for SchemeLayeredSocketFactory not  LayeredConnectionSocketFactory
in DefaultClientConnectionOperator.updateSecureConnection().

package org.apache.http.impl.conn;
class DefaultClientConnectionOperator
  updateSecureConnection()  {
...
// line 214
        Asserts.check(schm.getSchemeSocketFactory() instanceof LayeredConnectionSocketFactory,
            "Socket factory must implement SchemeLayeredSocketFactory");
        final SchemeLayeredSocketFactory lsf = (SchemeLayeredSocketFactory) schm.getSchemeSocketFactory();
  }


> DefaultClientConnectionOperator instance check inconsistent with explicit cast
> ------------------------------------------------------------------------------
>
>                 Key: HTTPCLIENT-1433
>                 URL: https://issues.apache.org/jira/browse/HTTPCLIENT-1433
>             Project: HttpComponents HttpClient
>          Issue Type: Bug
>          Components: HttpClient
>    Affects Versions: 4.3.1
>         Environment: exists in all platforms.
>            Reporter: jason mathews
>
> Class checks for LayeredConnectionSocketFactory instance then casts to SchemeLayeredSocketFactory
at line 214.
> Assertion check needs to be for SchemeLayeredSocketFactory not  LayeredConnectionSocketFactory
in DefaultClientConnectionOperator.updateSecureConnection().
> {code:java}
> package org.apache.http.impl.conn;
> class DefaultClientConnectionOperator
>   updateSecureConnection()  {
> ...
> // line 214
>         Asserts.check(schm.getSchemeSocketFactory() instanceof LayeredConnectionSocketFactory,
>             "Socket factory must implement SchemeLayeredSocketFactory");
>         final SchemeLayeredSocketFactory lsf = (SchemeLayeredSocketFactory) schm.getSchemeSocketFactory();
>   }
> {code}



--
This message was sent by Atlassian JIRA
(v6.1#6144)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@hc.apache.org
For additional commands, e-mail: dev-help@hc.apache.org


Mime
View raw message