logging-log4j-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From carn...@apache.org
Subject svn commit: r439033 - /logging/log4j/branches/v1_2-branch/src/java/org/apache/log4j/net/SMTPAppender.java
Date Thu, 31 Aug 2006 19:48:18 GMT
Author: carnold
Date: Thu Aug 31 12:48:17 2006
New Revision: 439033

URL: http://svn.apache.org/viewvc?rev=439033&view=rev
Log:
Bug 30294: SMTPAppender will not run within sandbox

Modified:
    logging/log4j/branches/v1_2-branch/src/java/org/apache/log4j/net/SMTPAppender.java

Modified: logging/log4j/branches/v1_2-branch/src/java/org/apache/log4j/net/SMTPAppender.java
URL: http://svn.apache.org/viewvc/logging/log4j/branches/v1_2-branch/src/java/org/apache/log4j/net/SMTPAppender.java?rev=439033&r1=439032&r2=439033&view=diff
==============================================================================
--- logging/log4j/branches/v1_2-branch/src/java/org/apache/log4j/net/SMTPAppender.java (original)
+++ logging/log4j/branches/v1_2-branch/src/java/org/apache/log4j/net/SMTPAppender.java Thu
Aug 31 12:48:17 2006
@@ -148,7 +148,12 @@
    *  @param mail session, may not be null.
    */
   protected Session createSession() {
-    Properties props = new Properties (System.getProperties());
+    Properties props = null;
+    try {
+        props = new Properties (System.getProperties());
+    } catch(SecurityException ex) {
+        props = new Properties();
+    }
     if (smtpHost != null) {
       props.put("mail.smtp.host", smtpHost);
     }



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


Mime
View raw message