Return-Path: X-Original-To: apmail-directory-dev-archive@www.apache.org Delivered-To: apmail-directory-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id E861A1829F for ; Wed, 15 Jul 2015 02:07:04 +0000 (UTC) Received: (qmail 50207 invoked by uid 500); 15 Jul 2015 02:07:04 -0000 Delivered-To: apmail-directory-dev-archive@directory.apache.org Received: (qmail 50150 invoked by uid 500); 15 Jul 2015 02:07:04 -0000 Mailing-List: contact dev-help@directory.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "Apache Directory Developers List" Delivered-To: mailing list dev@directory.apache.org Received: (qmail 50138 invoked by uid 99); 15 Jul 2015 02:07:04 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 15 Jul 2015 02:07:04 +0000 Date: Wed, 15 Jul 2015 02:07:04 +0000 (UTC) From: "Xu Yaning (JIRA)" To: dev@directory.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Updated] (DIRKRB-354) Fix getBooleanOption return null problem MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/DIRKRB-354?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Xu Yaning updated DIRKRB-354: ----------------------------- Attachment: DIRKRB-354-v3.patch I've updated the patch, pls help me review it. Thank you~ > Fix getBooleanOption return null problem > ---------------------------------------- > > Key: DIRKRB-354 > URL: https://issues.apache.org/jira/browse/DIRKRB-354 > Project: Directory Kerberos > Issue Type: Bug > Reporter: Xu Yaning > Assignee: Xu Yaning > Attachments: DIRKRB-354-v1.patch, DIRKRB-354-v2.patch, DIRKRB-354-v3.patch > > > org.apache.kerby.KOptions.getBooleanOption(KOption) has Boolean return type and returns explicit null; A method that returns either Boolean.TRUE, Boolean.FALSE or null is an accident waiting to happen. This method can be invoked as though it returned a value of type boolean, and the compiler will insert automatic unboxing of the Boolean value. If a null value is returned, this will result in a NullPointerException. -- This message was sent by Atlassian JIRA (v6.3.4#6332)