| Detector: | MuDetect_CrossProject |
| Target: | project ' synthetic ' versionmapkeynull |
| Misuse: | misuse ' mapkeynull ' |
| Tags: |
Details about the known misuse from the MUBench dataset.
| Description: | HashMap.get() throws if the key is null. Since you don't know which implementation of Map you get, you should always guard against this. |
| Fix Description: | Check that the key is not null before calling Map.get(). |
| Violation Types: |
|
| In File: | MapKeyNull.java |
| In Method: | misuse(HashMap, String) |
| Code with Misuse: |
|