changeset 15687:9f473a0b9e86

8006667: Merge issue: Profile attribute need to be examined before custom attributes Summary: swap profile checking and FXHelper checking Reviewed-by: alanb
author dholmes
date Tue, 22 Jan 2013 20:04:15 -0500
parents e0db54259c53
children 625addfb4d4c
files jdk/src/share/classes/sun/launcher/LauncherHelper.java
diffstat 1 files changed, 10 insertions(+), 9 deletions(-) [+]
line wrap: on
line diff
--- a/jdk/src/share/classes/sun/launcher/LauncherHelper.java	Tue Jan 22 19:31:02 2013 -0500
+++ b/jdk/src/share/classes/sun/launcher/LauncherHelper.java	Tue Jan 22 20:04:15 2013 -0500
@@ -413,15 +413,6 @@
             if (mainValue == null) {
                 abort(null, "java.launcher.jar.error3", jarname);
             }
-            /*
-             * Hand off to FXHelper if it detects a JavaFX application
-             * This must be done after ensuring a Main-Class entry
-             * exists to enforce compliance with the jar specification
-             */
-            if (mainAttrs.containsKey(
-                    new Attributes.Name(FXHelper.JAVAFX_APPLICATION_MARKER))) {
-                return FXHelper.class.getName();
-            }
 
             /*
              * If this is not a full JRE then the Profile attribute must be
@@ -444,6 +435,16 @@
                 }
             }
 
+            /*
+             * Hand off to FXHelper if it detects a JavaFX application
+             * This must be done after ensuring a Main-Class entry
+             * exists to enforce compliance with the jar specification
+             */
+            if (mainAttrs.containsKey(
+                    new Attributes.Name(FXHelper.JAVAFX_APPLICATION_MARKER))) {
+                return FXHelper.class.getName();
+            }
+
             return mainValue.trim();
         } catch (IOException ioe) {
             abort(ioe, "java.launcher.jar.error1", jarname);