tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jfarc...@apache.org
Subject cvs commit: jakarta-tomcat-connectors/util/java/org/apache/tomcat/util/net SSLImplementation.java
Date Sun, 13 Apr 2003 14:27:10 GMT
jfarcand    2003/04/13 07:27:10

  Modified:    util/java/org/apache/tomcat/util/net SSLImplementation.java
  Log:
  Ugly workaround for the "ClassNotFound" Exception that occurs under Solaris/j2se 1.4.x.
SSL is curently broken without this hack.
  
  Please revert the patch if you have a better idea.
  
  Revision  Changes    Path
  1.3       +13 -4     jakarta-tomcat-connectors/util/java/org/apache/tomcat/util/net/SSLImplementation.java
  
  Index: SSLImplementation.java
  ===================================================================
  RCS file: /home/cvs/jakarta-tomcat-connectors/util/java/org/apache/tomcat/util/net/SSLImplementation.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- SSLImplementation.java	4 Oct 2002 20:03:10 -0000	1.2
  +++ SSLImplementation.java	13 Apr 2003 14:27:10 -0000	1.3
  @@ -77,19 +77,28 @@
       
       private static final String[] implementations=
       {
  -	PureTLSImplementationClass,
  -	JSSEImplementationClass
  +        JSSEImplementationClass,
  +        PureTLSImplementationClass
       };
   
       public static SSLImplementation getInstance() throws ClassNotFoundException
       {
   	for(int i=0;i<implementations.length;i++){
  +        // Workaround for the J2SE 1.4.x classloading problem (under Solaris).
  +        // Class.forName(..) fails without creating class using new.
  +        // This is an ugly workaround. 
  +        try{
  +            new org.apache.tomcat.util.net.jsse.JSSEImplementation();
  +        }catch (Exception e){
  +            //e.printStackTrace();
  +        }    
  +
   	    try {
  -		SSLImplementation impl=
  +               SSLImplementation impl=
   		    getInstance(implementations[i]);
   		return impl;
   	    } catch (Exception e) {
  -		//e.printStackTrace();
  +            //e.printStackTrace();
   	    }
   	}
   
  
  
  

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


Mime
View raw message