You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@sentry.apache.org by "Haley Reeve (JIRA)" <ji...@apache.org> on 2018/12/17 20:09:00 UTC
[jira] [Commented] (SENTRY-1657) Possible null-pointer dereference
in SentryMain
[ https://issues.apache.org/jira/browse/SENTRY-1657?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16723328#comment-16723328 ]
Haley Reeve commented on SENTRY-1657:
-------------------------------------
[~akolb], this seems to have been rendered irrelevant by changes in SENTRY-1572. The code you reference above no longer exists.
> Possible null-pointer dereference in SentryMain
> -----------------------------------------------
>
> Key: SENTRY-1657
> URL: https://issues.apache.org/jira/browse/SENTRY-1657
> Project: Sentry
> Issue Type: Bug
> Components: Sentry
> Affects Versions: 1.8.0
> Reporter: Alexander Kolbasov
> Assignee: Arjun Mishra
> Priority: Minor
> Labels: bite-sized, newbie
>
> In SentryMain.java there is the following code:
> {code}
> String commandClazz = COMMANDS.get(commandName);
> if (commandClazz == null) { // may be null here
> printHelp(options, "Unknown command " + commandName + "\n");
> }
> Object command;
> try {
> command = Class.forName(commandClazz.trim()).newInstance(); // dereference null here
> ...
> {code}
> Note that commandClazz may be null and yet be dereferenced.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)