coverity#1326293 Dereference after null check
Change-Id: I6ce295873eb2ed1231ad1d95babfcc2c8ff265e8
This commit is contained in:
parent
293dd731e9
commit
f40120dc6f
1 changed files with 13 additions and 15 deletions
|
@ -41,13 +41,12 @@ public class _XExactName extends MultiMethodTest {
|
|||
if (getting == null) {
|
||||
res = false;
|
||||
} else {
|
||||
res = getting.equals(expectedName);
|
||||
}
|
||||
|
||||
if (!res) {
|
||||
if (!getting.equals(expectedName)) {
|
||||
log.println("didn't get the expected Name:");
|
||||
log.println("getting: " + getting);
|
||||
log.println("Expected: " + expectedName);
|
||||
res = false;
|
||||
}
|
||||
}
|
||||
|
||||
nameFor = expectedName.toUpperCase();
|
||||
|
@ -58,13 +57,12 @@ public class _XExactName extends MultiMethodTest {
|
|||
if (getting == null) {
|
||||
res = false;
|
||||
} else {
|
||||
res &= getting.equals(expectedName);
|
||||
}
|
||||
|
||||
if (!getting.equals(expectedName)) {
|
||||
log.println("didn't get the expected Name:");
|
||||
log.println("getting: " + getting);
|
||||
log.println("Expected: " + expectedName);
|
||||
res = false;
|
||||
}
|
||||
}
|
||||
|
||||
tRes.tested("getExactName()", res);
|
||||
|
|
Loading…
Reference in a new issue