提交 7f0b7f34 编写于 作者: B bagiras

7185678: java/awt/Menu/NullMenuLabelTest/NullMenuLabelTest.java failed with NPE

Reviewed-by: art, ahgross
上级 8fb3907e
......@@ -202,7 +202,8 @@ public class XMenuItemPeer implements MenuItemPeer {
if (target == null) {
return "";
}
return AWTAccessor.getMenuItemAccessor().getLabel(target);
String label = AWTAccessor.getMenuItemAccessor().getLabel(target);
return (label == null) ? "" : label;
}
boolean isTargetEnabled() {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册