cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dk...@apache.org
Subject svn commit: r1497519 - /cxf/branches/2.6.x-fixes/api/src/main/java/org/apache/cxf/common/logging/JDKBugHacks.java
Date Thu, 27 Jun 2013 19:41:47 GMT
Author: dkulp
Date: Thu Jun 27 19:41:47 2013
New Revision: 1497519

URL: http://svn.apache.org/r1497519
Log:
Merged revisions 1495119 via  git cherry-pick from
https://svn.apache.org/repos/asf/cxf/branches/2.7.x-fixes

........
  r1495119 | dkulp | 2013-06-20 14:16:43 -0400 (Thu, 20 Jun 2013) | 10 lines

  Merged revisions 1494805 via  git cherry-pick from
  https://svn.apache.org/repos/asf/cxf/trunk

  ........
    r1494805 | dkulp | 2013-06-19 19:37:40 -0400 (Wed, 19 Jun 2013) | 2 lines

    Skip the IOImage hack by default.  With the very latest JDK's on OSX, it will immediately
create a bouncing java icon on the Dock. Since use of Images is fairly rare, it's likely not
needed very often and it can be turned on if needed.

  ........

........

Modified:
    cxf/branches/2.6.x-fixes/api/src/main/java/org/apache/cxf/common/logging/JDKBugHacks.java

Modified: cxf/branches/2.6.x-fixes/api/src/main/java/org/apache/cxf/common/logging/JDKBugHacks.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.6.x-fixes/api/src/main/java/org/apache/cxf/common/logging/JDKBugHacks.java?rev=1497519&r1=1497518&r2=1497519&view=diff
==============================================================================
--- cxf/branches/2.6.x-fixes/api/src/main/java/org/apache/cxf/common/logging/JDKBugHacks.java
(original)
+++ cxf/branches/2.6.x-fixes/api/src/main/java/org/apache/cxf/common/logging/JDKBugHacks.java
Thu Jun 27 19:41:47 2013
@@ -54,6 +54,9 @@ final class JDKBugHacks {
     }
     
     private static boolean skipHack(final String key) {
+        return skipHack(key, "false");
+    }
+    private static boolean skipHack(final String key, String def) {
         String cname = null;
         try {
             cname = AccessController.doPrivileged(new PrivilegedAction<String>() {
@@ -82,8 +85,8 @@ final class JDKBugHacks {
         } catch (Throwable t) {
             //ignore
         }
-        if (cname == null) {
-            cname = "false";
+        if (StringUtils.isEmpty(cname)) {
+            cname = def;
         }
         return Boolean.parseBoolean(cname);
     }
@@ -100,7 +103,7 @@ final class JDKBugHacks {
             try {
                 try {
                     //Trigger a call to sun.awt.AppContext.getAppContext()
-                    if (!skipHack("org.apache.cxf.JDKBugHacks.imageIO")) {
+                    if (!skipHack("org.apache.cxf.JDKBugHacks.imageIO", "true")) {
                         ImageIO.getCacheDirectory();
                     }
                 } catch (Throwable t) {



Mime
View raw message