Commit c113e8a
authored
Fix SpotBugs null pointer dereference warnings (#4322)
* Fix SpotBugs null pointer dereference warnings
Addressed 12 SpotBugs "Possible null pointer dereference" warnings across 8 files:
- CodenameOneImplementation.java: Fixed null usage in captureAudio logging and data check.
- InteractionDialog.java: Added null check for rect.
- SimpleDateFormat.java: Added return statements to throwInvalid calls.
- HashtableContent.java: Added null check for node.
- Form.java: Added null checks for components in layered pane iteration.
- DefaultLookAndFeel.java: Added null checks for badgeStyle.
- SpinnerNode.java: Added null check for selectionListeners before calling isEmpty().
- CommonTransitions.java: Added default case to switch statement.
* Fix SpotBugs null pointer dereference warnings
Addressed 12 SpotBugs "Possible null pointer dereference" warnings across 8 files:
- CodenameOneImplementation.java: Fixed null usage in captureAudio logging and data check.
- InteractionDialog.java: Added explicit null checks for Component and Rectangle arguments in showPopupDialog.
- SimpleDateFormat.java: Added return statements to throwInvalid calls.
- HashtableContent.java: Added null check for node.
- Form.java: Added null checks for components in layered pane iteration and safely handled null Class argument in getLayeredPane.
- DefaultLookAndFeel.java: Added null checks for badgeStyle.
- SpinnerNode.java: Added null check for selectionListeners before calling isEmpty().
- CommonTransitions.java: Added default case to switch statement.
---------
Co-authored-by: google-labs-jules[bot] <161369871+google-labs-jules[bot]@users.noreply.github.com>1 parent 79bc59b commit c113e8a
File tree
8 files changed
+56
-26
lines changed- CodenameOne/src/com/codename1
- components
- impl
- l10n
- processing
- ui
- animations
- plaf
- spinner
8 files changed
+56
-26
lines changedLines changed: 7 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
630 | 630 | | |
631 | 631 | | |
632 | 632 | | |
633 | | - | |
| 633 | + | |
| 634 | + | |
| 635 | + | |
| 636 | + | |
634 | 637 | | |
635 | 638 | | |
636 | 639 | | |
| |||
664 | 667 | | |
665 | 668 | | |
666 | 669 | | |
| 670 | + | |
| 671 | + | |
| 672 | + | |
667 | 673 | | |
668 | 674 | | |
669 | 675 | | |
| |||
Lines changed: 5 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5812 | 5812 | | |
5813 | 5813 | | |
5814 | 5814 | | |
5815 | | - | |
| 5815 | + | |
5816 | 5816 | | |
5817 | 5817 | | |
5818 | 5818 | | |
| |||
5997 | 5997 | | |
5998 | 5998 | | |
5999 | 5999 | | |
6000 | | - | |
6001 | | - | |
| 6000 | + | |
| 6001 | + | |
| 6002 | + | |
| 6003 | + | |
6002 | 6004 | | |
6003 | 6005 | | |
6004 | 6006 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
964 | 964 | | |
965 | 965 | | |
966 | 966 | | |
967 | | - | |
| 967 | + | |
968 | 968 | | |
969 | 969 | | |
970 | 970 | | |
| |||
1066 | 1066 | | |
1067 | 1067 | | |
1068 | 1068 | | |
1069 | | - | |
| 1069 | + | |
1070 | 1070 | | |
1071 | 1071 | | |
1072 | 1072 | | |
| |||
1076 | 1076 | | |
1077 | 1077 | | |
1078 | 1078 | | |
1079 | | - | |
| 1079 | + | |
1080 | 1080 | | |
1081 | 1081 | | |
1082 | 1082 | | |
| |||
Lines changed: 7 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
197 | 197 | | |
198 | 198 | | |
199 | 199 | | |
| 200 | + | |
| 201 | + | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
| 206 | + | |
200 | 207 | | |
201 | 208 | | |
202 | 209 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1430 | 1430 | | |
1431 | 1431 | | |
1432 | 1432 | | |
1433 | | - | |
| 1433 | + | |
1434 | 1434 | | |
1435 | 1435 | | |
1436 | 1436 | | |
1437 | 1437 | | |
1438 | | - | |
| 1438 | + | |
1439 | 1439 | | |
1440 | 1440 | | |
1441 | 1441 | | |
1442 | 1442 | | |
1443 | 1443 | | |
1444 | | - | |
1445 | | - | |
1446 | | - | |
| 1444 | + | |
| 1445 | + | |
| 1446 | + | |
| 1447 | + | |
| 1448 | + | |
1447 | 1449 | | |
1448 | 1450 | | |
1449 | 1451 | | |
| |||
1491 | 1493 | | |
1492 | 1494 | | |
1493 | 1495 | | |
1494 | | - | |
| 1496 | + | |
1495 | 1497 | | |
1496 | 1498 | | |
1497 | 1499 | | |
1498 | 1500 | | |
1499 | | - | |
| 1501 | + | |
1500 | 1502 | | |
1501 | 1503 | | |
1502 | 1504 | | |
1503 | 1505 | | |
1504 | 1506 | | |
1505 | | - | |
1506 | | - | |
1507 | | - | |
| 1507 | + | |
| 1508 | + | |
| 1509 | + | |
| 1510 | + | |
| 1511 | + | |
1508 | 1512 | | |
1509 | 1513 | | |
1510 | 1514 | | |
| |||
Lines changed: 3 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1304 | 1304 | | |
1305 | 1305 | | |
1306 | 1306 | | |
| 1307 | + | |
| 1308 | + | |
| 1309 | + | |
1307 | 1310 | | |
1308 | 1311 | | |
1309 | 1312 | | |
| |||
Lines changed: 14 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1612 | 1612 | | |
1613 | 1613 | | |
1614 | 1614 | | |
1615 | | - | |
1616 | | - | |
1617 | | - | |
| 1615 | + | |
| 1616 | + | |
| 1617 | + | |
| 1618 | + | |
| 1619 | + | |
| 1620 | + | |
| 1621 | + | |
1618 | 1622 | | |
1619 | 1623 | | |
1620 | 1624 | | |
1621 | 1625 | | |
1622 | 1626 | | |
1623 | | - | |
1624 | | - | |
1625 | | - | |
| 1627 | + | |
| 1628 | + | |
| 1629 | + | |
| 1630 | + | |
| 1631 | + | |
| 1632 | + | |
| 1633 | + | |
1626 | 1634 | | |
1627 | 1635 | | |
1628 | 1636 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
239 | 239 | | |
240 | 240 | | |
241 | 241 | | |
242 | | - | |
243 | | - | |
244 | | - | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
245 | 245 | | |
246 | 246 | | |
247 | 247 | | |
| |||
0 commit comments