Details
-
Type:
Bug
-
Status: Resolved
-
Priority:
P4
-
Resolution: Fixed
-
Affects Version/s: 8, 11, 13, 15, 16, 17
-
Fix Version/s: 17
-
Component/s: client-libs
-
Labels:
-
Subcomponent:
-
Resolved In Build:b14
Description
SonarCloud reports:
Remove or correct this "removeAll" call.
void removeAll() {
items.removeAll(items); // <--- here
updateScrollbars();
}
Calling removeAll with the same collection risks concurrent modification exceptions. clear() would be correct and more efficient.
Remove or correct this "removeAll" call.
void removeAll() {
items.removeAll(items); // <--- here
updateScrollbars();
}
Calling removeAll with the same collection risks concurrent modification exceptions. clear() would be correct and more efficient.