Summary: | Incorrect flagging of potential null pointer access | ||
---|---|---|---|
Product: | [Eclipse Project] JDT | Reporter: | Darin Swanson <Darin_Swanson> |
Component: | Core | Assignee: | Maxime Daniel <maxime_daniel> |
Status: | VERIFIED INVALID | QA Contact: | |
Severity: | normal | ||
Priority: | P3 | ||
Version: | 3.3 | ||
Target Milestone: | 3.3 M7 | ||
Hardware: | PC | ||
OS: | Windows XP | ||
Whiteboard: |
Description
Darin Swanson
2007-03-24 14:23:30 EDT
If any of oldArgs or newArgs is not null, then oldArgs.size() != newArgs.size() gets executed. Therefore if one of them is null and not the other, we get an NPE at runtime. Contrast this with: for (...) { ... if (oldArgs == null || newArgs == null) { continue; } if(oldArgs.size() != newArgs.size()) { return true; } ... } which must not (and does not) complain. I believe there is no problem here. I will read the complete test case tomorrow to see whether it has been oversimplified. Sorry...you are entirely correct. There is no problem here. No problem. Closing as invalid. Verified for 3.3M7 |