mirror of https://github.com/OpenIdentityPlatform/OpenDJ.git

fguigues
21.29.2009 dec2fa45c543011663cd1724d7e682a4d6a7421d
Fix Issue 4240 : NPE in Simplified LDIF view with specific entries
* In the case of a Regex Syntax, there is no name.

1 files modified
7 ■■■■ changed files
opendj-sdk/opends/src/guitools/org/opends/guitools/controlpanel/ui/SimplifiedViewEntryPanel.java 7 ●●●● patch | view | raw | blame | history
opendj-sdk/opends/src/guitools/org/opends/guitools/controlpanel/ui/SimplifiedViewEntryPanel.java
@@ -1533,12 +1533,15 @@
        AttributeType attr = schema.getAttributeType(attrName.toLowerCase());
        if (attr != null)
        {
          mustAddBrowseButton =
            attr.getSyntax().getSyntaxName().equalsIgnoreCase(
          // There is no name for a regex syntax.
          String syntaxName = attr.getSyntax().getSyntaxName();
          if (syntaxName!=null) {
              mustAddBrowseButton=syntaxName.equalsIgnoreCase(
                SchemaConstants.SYNTAX_DN_NAME);
        }
      }
    }
    }
    return mustAddBrowseButton;
  }