42 lines
1.5 KiB
Plaintext
42 lines
1.5 KiB
Plaintext
=== on 23 Mar 2015, 13:15:46 Freddy Mallet wrote:
|
|
@Ann, could you review this sub-task ? Thanks
|
|
|
|
=== on 24 Mar 2015, 12:47:38 Samuel Mercier wrote:
|
|
first example is wrong, since ``++instanceof++`` would return ``++false++`` if ``++obj++`` is ``++null++``.
|
|
|
|
Interestingly, from null/notnull point of view, ``++a instanceof b++`` is equivalent to ``++a != null++``
|
|
|
|
=== on 24 Mar 2015, 13:45:55 Samuel Mercier wrote:
|
|
\[~ann.campbell.2] I updated the first non compliant code snippet.
|
|
|
|
=== on 24 Mar 2015, 15:02:13 Samuel Mercier wrote:
|
|
Removed message * NullPointerException will be thrown as 'XXXX' is for sure null here, since we are currently unable to make distinction between @Nullable and if (... == null)
|
|
|
|
=== on 19 Sep 2019, 05:14:31 QXO wrote:
|
|
This code shouldnot should not be a issue ( in `url.substring(0,start)` url never not null)
|
|
|
|
It's sonarqube(7.9.1) check implements issue, please fix the issue:)
|
|
|
|
----
|
|
public String testSonarNullCheckIssue(final String url,final boolean isUrl) {
|
|
int start = url != null && isUrl ? url.indexOf('?') : -1;
|
|
if(start != -1 ){
|
|
return url.substring(0,start);
|
|
}
|
|
return url;
|
|
} {code}
|
|
|
|
ref: https://drive.google.com/open?id=1MuZMBm8bkwz_Q5mZIwEaDsJoh-qaopW_
|
|
----
|
|
|
|
=== on 19 Sep 2019, 07:24:31 Alexandre Gigleux wrote:
|
|
Thanks for the feedback [~qxo]!
|
|
|
|
Can you report the FP in the community forum \https://community.sonarsource.com/tags/c/bug/fp/java so it gets more visibility and be addressed?
|
|
|
|
JIRA comments are not convenient to manage FPs.
|
|
|
|
Thanks
|
|
|
|
include::../comments-and-links.adoc[]
|