Return-Path: X-Original-To: apmail-directory-commits-archive@www.apache.org Delivered-To: apmail-directory-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 7328010D20 for ; Fri, 2 Aug 2013 11:21:11 +0000 (UTC) Received: (qmail 17851 invoked by uid 500); 2 Aug 2013 11:21:11 -0000 Delivered-To: apmail-directory-commits-archive@directory.apache.org Received: (qmail 17774 invoked by uid 500); 2 Aug 2013 11:21:05 -0000 Mailing-List: contact commits-help@directory.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@directory.apache.org Delivered-To: mailing list commits@directory.apache.org Received: (qmail 17764 invoked by uid 99); 2 Aug 2013 11:21:03 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 02 Aug 2013 11:21:03 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 02 Aug 2013 11:21:01 +0000 Received: from eris.apache.org (localhost [127.0.0.1]) by eris.apache.org (Postfix) with ESMTP id 8EE6123888E2; Fri, 2 Aug 2013 11:20:40 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r1509631 - /directory/shared/trunk/ldap/model/src/main/java/org/apache/directory/api/ldap/model/entry/DefaultEntry.java Date: Fri, 02 Aug 2013 11:20:40 -0000 To: commits@directory.apache.org From: elecharny@apache.org X-Mailer: svnmailer-1.0.9 Message-Id: <20130802112040.8EE6123888E2@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Author: elecharny Date: Fri Aug 2 11:20:40 2013 New Revision: 1509631 URL: http://svn.apache.org/r1509631 Log: Fixed a potential NPE Modified: directory/shared/trunk/ldap/model/src/main/java/org/apache/directory/api/ldap/model/entry/DefaultEntry.java Modified: directory/shared/trunk/ldap/model/src/main/java/org/apache/directory/api/ldap/model/entry/DefaultEntry.java URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/model/src/main/java/org/apache/directory/api/ldap/model/entry/DefaultEntry.java?rev=1509631&r1=1509630&r2=1509631&view=diff ============================================================================== --- directory/shared/trunk/ldap/model/src/main/java/org/apache/directory/api/ldap/model/entry/DefaultEntry.java (original) +++ directory/shared/trunk/ldap/model/src/main/java/org/apache/directory/api/ldap/model/entry/DefaultEntry.java Fri Aug 2 11:20:40 2013 @@ -2590,7 +2590,11 @@ public final class DefaultEntry implemen { AttributeType attributeType = schemaManager.getAttributeType( id ); - if ( !attributeType.equals( objectClassAttributeType ) ) + if ( attributeType == null ) + { + sb.append( tabs + "id: " + id ); + } + else if ( !attributeType.equals( objectClassAttributeType ) ) { sb.append( attribute.toString( tabs + " " ) ); continue;