[ 
https://issues.apache.org/jira/browse/KAFKA-6899?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

lujie updated KAFKA-6899:
-------------------------
    Summary: One Potential NPEs   (was: OnePotential NPEs)

> One Potential NPEs 
> -------------------
>
>                 Key: KAFKA-6899
>                 URL: https://issues.apache.org/jira/browse/KAFKA-6899
>             Project: Kafka
>          Issue Type: Bug
>            Reporter: lujie
>            Priority: Major
>
> We have developed a static analysis tool 
> [NPEDetector|https://github.com/lujiefsi/NPEDetector] to find some potential 
> NPE. Our analysis shows that NPE reason can be simple:some callees may return 
> null directly in corner case(e.g. node crash , IO exception), some of their 
> callers have  _!=null_ check but some do not have. 
> *Bug:*
> callee JaasConfig#getAppConfigurationEntry  can return null, it has 13 
> callers, 11 of the callers have the null check while using the return value, 
> one of them have no checker :
> {code:java}
> //caller:KerberosLogin#login()
> AppConfigurationEntry[] entries = 
> configuration().getAppConfigurationEntry(contextName());
> if (entries.length == 0)/may NPE
> {code}
> I am not sure whether it is an bug or not, please correct me without any 
> without any hesitation.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to