| Summary: | GraphViewer#findGraphItem(object) throws ArrayIndexOutOfBoundsException instead of returning null | ||
|---|---|---|---|
| Product: | [Tools] GEF | Reporter: | David Savage <david.savage> |
| Component: | GEF-Legacy Zest | Assignee: | Ian Bull <irbull> |
| Status: | RESOLVED FIXED | QA Contact: | |
| Severity: | normal | ||
| Priority: | P3 | ||
| Version: | unspecified | ||
| Target Milestone: | --- | ||
| Hardware: | All | ||
| OS: | All | ||
| Whiteboard: | |||
looks as if this was fixed. I think I did this with a few other fixes earlier this month. Thanks for pointing ths out. |
The code within findGraphItem does the following: public GraphItem findGraphItem(Object element) { Widget[] result = findItems(element); return (result.length == 0 && result[0] instanceof GraphItem) ? null : (GraphItem) result[0]; } this should be: return (result.length == 0 || !(result[0] instanceof GraphItem)) ? null : (GraphItem) result[0];