billbarker    01/12/25 21:25:30

  Modified:    src/share/org/apache/tomcat/util/net
                        StreamHandlerFactory.java
  Log:
  It seems that some JVMs handle "jar" specially, so decline if the protocol is "jar"
  
  Revision  Changes    Path
  1.5       +3 -0      
jakarta-tomcat/src/share/org/apache/tomcat/util/net/StreamHandlerFactory.java
  
  Index: StreamHandlerFactory.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/util/net/StreamHandlerFactory.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- StreamHandlerFactory.java 2001/11/18 05:56:02     1.4
  +++ StreamHandlerFactory.java 2001/12/26 05:25:30     1.5
  @@ -86,12 +86,15 @@
       /** Create a <code>URLStreamHandler</code> for this protocol.
        *  This factory differs from the default in that
        *  <ul>
  +     *  <li>If the protocol is <code>jar</code>, we decline</li>
        *  <li>We load classes from the <code>ContextClassLoader</code></li>
        *  <li>If no handler is defined, we return a connection-less
        *       <code>URLStreamHandler</code> that allows parsing</li>
        *  </ul>
        */
       public  URLStreamHandler createURLStreamHandler(String protoS) {
  +     if("jar".equalsIgnoreCase(protoS))
  +         return null;
        if(protocolString != System.getProperty(SYS_PROTOCOLS))
            loadProtocols();
        ClassLoader acl = jdk11Compat.getContextClassLoader();
  
  
  

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to