changeset 7404:bf7120252a95

8009996: tests javax/management/mxbean/MiscTest.java and javax/management/mxbean/StandardMBeanOverrideTest.java fail Reviewed-by: dfuchs, dholmes
author jbachorik
date Mon, 18 Mar 2013 11:17:06 +0100
parents 9f99c9ab588b
children 59ced5cf8344
files src/share/classes/javax/management/StandardEmitterMBean.java
diffstat 1 files changed, 5 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/src/share/classes/javax/management/StandardEmitterMBean.java	Fri Mar 15 12:31:57 2013 -0700
+++ b/src/share/classes/javax/management/StandardEmitterMBean.java	Mon Mar 18 11:17:06 2013 +0100
@@ -258,6 +258,11 @@
     }
 
     public MBeanNotificationInfo[] getNotificationInfo() {
+        // this getter might get called from the super constructor
+        // when the notificationInfo has not been properly set yet
+        if (notificationInfo == null) {
+            return NO_NOTIFICATION_INFO;
+        }
         if (notificationInfo.length == 0) {
             return notificationInfo;
         } else {