The following document contains the results of SpotBugs
SpotBugs Version is 4.7.1
Threshold is medium
Effort is default
Classes | Bugs | Errors | Missing Classes |
---|---|---|---|
28 | 40 | 0 | 0 |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
Dead store to params in nl.tudelft.simulation.dsol.jetty.sse.OtsWebModel.handle(String, Request, HttpServletRequest, HttpServletResponse) | STYLE | DLS_DEAD_LOCAL_STORE | 244 | Medium |
nl.tudelft.simulation.dsol.jetty.sse.OtsWebModel.getAnimationPanel() may expose internal representation by returning OtsWebModel.animationPanel | MALICIOUS_CODE | EI_EXPOSE_REP | 123 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
nl.tudelft.simulation.dsol.jetty.sse.OtsWebServer.getAnimationPanel() may expose internal representation by returning OtsWebServer.animationPanel | MALICIOUS_CODE | EI_EXPOSE_REP | 158 | Medium |
new nl.tudelft.simulation.dsol.jetty.sse.OtsWebServer(String, OtsSimulatorInterface, Bounds2d) invokes nl.tudelft.simulation.dsol.jetty.sse.OtsWebServer$ServerThread.start() | MT_CORRECTNESS | SC_START_IN_CTOR | 100 | High |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
Hard coded reference to an absolute pathname in nl.tudelft.simulation.dsol.jetty.sse.OtsWebServer$ServerThread.run() | STYLE | DMI_HARDCODED_ABSOLUTE_FILENAME | 113 | High |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
Dead store to params in nl.tudelft.simulation.dsol.jetty.sse.OtsWebServer$XHRHandler.handle(String, Request, HttpServletRequest, HttpServletResponse) | STYLE | DLS_DEAD_LOCAL_STORE | 277 | Medium |
new nl.tudelft.simulation.dsol.jetty.sse.OtsWebServer$XHRHandler(OtsWebServer) may expose internal representation by storing an externally mutable object into OtsWebServer$XHRHandler.webServer | MALICIOUS_CODE | EI_EXPOSE_REP2 | 266 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
Hard coded reference to an absolute pathname in nl.tudelft.simulation.dsol.jetty.sse.TestDemoServer$ServerThread.run() | STYLE | DMI_HARDCODED_ABSOLUTE_FILENAME | 101 | High |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
Boxing/unboxing to parse a primitive nl.tudelft.simulation.dsol.jetty.sse.TestDemoServer$XHRHandler.setParameters(OtsModelInterface, String) | PERFORMANCE | DM_BOXED_PRIMITIVE_FOR_PARSING | 503 | High |
Boxing/unboxing to parse a primitive nl.tudelft.simulation.dsol.jetty.sse.TestDemoServer$XHRHandler.setParameters(OtsModelInterface, String) | PERFORMANCE | DM_BOXED_PRIMITIVE_FOR_PARSING | 508 | High |
Boxing/unboxing to parse a primitive nl.tudelft.simulation.dsol.jetty.sse.TestDemoServer$XHRHandler.setParameters(OtsModelInterface, String) | PERFORMANCE | DM_BOXED_PRIMITIVE_FOR_PARSING | 523 | High |
Boxing/unboxing to parse a primitive nl.tudelft.simulation.dsol.jetty.sse.TestDemoServer$XHRHandler.setParameters(OtsModelInterface, String) | PERFORMANCE | DM_BOXED_PRIMITIVE_FOR_PARSING | 518 | High |
Exception is caught when Exception is not thrown in nl.tudelft.simulation.dsol.jetty.sse.TestDemoServer$XHRHandler.setParameters(OtsModelInterface, String) | STYLE | REC_CATCH_EXCEPTION | 551 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
nl.tudelft.simulation.dsol.web.animation.HtmlDevice.getConfigurations() may expose internal representation by returning HtmlDevice.htmlGraphicsConfigurations | MALICIOUS_CODE | EI_EXPOSE_REP | 53 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
nl.tudelft.simulation.dsol.web.animation.HtmlGraphics2d.getRenderingHints() may expose internal representation by returning HtmlGraphics2d.renderingHints | MALICIOUS_CODE | EI_EXPOSE_REP | 658 | Medium |
nl.tudelft.simulation.dsol.web.animation.HtmlGraphics2d.getTransform() may expose internal representation by returning HtmlGraphics2d.affineTransform | MALICIOUS_CODE | EI_EXPOSE_REP | 729 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
nl.tudelft.simulation.dsol.web.animation.HtmlGraphicsConfiguration.getBounds() may expose internal representation by returning HtmlGraphicsConfiguration.bounds | MALICIOUS_CODE | EI_EXPOSE_REP | 98 | Medium |
nl.tudelft.simulation.dsol.web.animation.HtmlGraphicsConfiguration.getDefaultTransform() may expose internal representation by returning HtmlGraphicsConfiguration.identityTransform | MALICIOUS_CODE | EI_EXPOSE_REP | 82 | Medium |
nl.tudelft.simulation.dsol.web.animation.HtmlGraphicsConfiguration.getDevice() may expose internal representation by returning HtmlGraphicsConfiguration.htmlDevice | MALICIOUS_CODE | EI_EXPOSE_REP | 47 | Medium |
nl.tudelft.simulation.dsol.web.animation.HtmlGraphicsConfiguration.getNormalizingTransform() may expose internal representation by returning HtmlGraphicsConfiguration.identityTransform | MALICIOUS_CODE | EI_EXPOSE_REP | 90 | Medium |
nl.tudelft.simulation.dsol.web.animation.HtmlGraphicsConfiguration.setDevice(HtmlDevice) may expose internal representation by storing an externally mutable object into HtmlGraphicsConfiguration.htmlDevice | MALICIOUS_CODE | EI_EXPOSE_REP2 | 58 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
nl.tudelft.simulation.dsol.web.animation.HtmlGraphicsEnvironment.createGraphics(BufferedImage) may expose internal representation by returning HtmlGraphicsEnvironment.graphics2D | MALICIOUS_CODE | EI_EXPOSE_REP | 67 | Medium |
nl.tudelft.simulation.dsol.web.animation.HtmlGraphicsEnvironment.getDefaultScreenDevice() may expose internal representation by returning HtmlGraphicsEnvironment.htmlDevice | MALICIOUS_CODE | EI_EXPOSE_REP | 59 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
nl.tudelft.simulation.dsol.web.animation.d2.HtmlAnimationPanel.getDragLine() may expose internal representation by returning HtmlAnimationPanel.dragLine | MALICIOUS_CODE | EI_EXPOSE_REP | 385 | Medium |
nl.tudelft.simulation.dsol.web.animation.d2.HtmlAnimationPanel.getToggleButtons() may expose internal representation by returning HtmlAnimationPanel.toggleButtons | MALICIOUS_CODE | EI_EXPOSE_REP | 575 | Medium |
nl.tudelft.simulation.dsol.web.animation.d2.HtmlAnimationPanel.isShowClass(Class) makes inefficient use of keySet iterator instead of entrySet iterator | PERFORMANCE | WMI_WRONG_MAP_ITERATOR | 187 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
nl.tudelft.simulation.dsol.web.animation.d2.HtmlGridPanel.getPreferredSize() may expose internal representation by returning HtmlGridPanel.preferredSize | MALICIOUS_CODE | EI_EXPOSE_REP | 519 | Medium |
nl.tudelft.simulation.dsol.web.animation.d2.HtmlGridPanel.getSize() may expose internal representation by returning HtmlGridPanel.size | MALICIOUS_CODE | EI_EXPOSE_REP | 471 | Medium |
nl.tudelft.simulation.dsol.web.animation.d2.HtmlGridPanel.setPreferredSize(Dimension) may expose internal representation by storing an externally mutable object into HtmlGridPanel.preferredSize | MALICIOUS_CODE | EI_EXPOSE_REP2 | 527 | Medium |
nl.tudelft.simulation.dsol.web.animation.d2.HtmlGridPanel.setSize(Dimension) may expose internal representation by storing an externally mutable object into HtmlGridPanel.size | MALICIOUS_CODE | EI_EXPOSE_REP2 | 479 | Medium |
Inconsistent synchronization of nl.tudelft.simulation.dsol.web.animation.d2.HtmlGridPanel.extent; locked 92% of time | MT_CORRECTNESS | IS2_INCONSISTENT_SYNC | 198 | Medium |
Inconsistent synchronization of nl.tudelft.simulation.dsol.web.animation.d2.HtmlGridPanel.renderableScale; locked 60% of time | MT_CORRECTNESS | IS2_INCONSISTENT_SYNC | 454 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
Random object created and used only once in org.opentrafficsim.web.test.CircularRoadModel.constructModel() | BAD_PRACTICE | DMI_RANDOM_USED_ONLY_ONCE | 216 | High |
org.opentrafficsim.web.test.CircularRoadModel.getMinimumDistance() may expose internal representation by returning CircularRoadModel.minimumDistance | MALICIOUS_CODE | EI_EXPOSE_REP | 283 | Medium |
org.opentrafficsim.web.test.CircularRoadModel.getNetwork() may expose internal representation by returning CircularRoadModel.network | MALICIOUS_CODE | EI_EXPOSE_REP | 275 | Medium |
Using floating-point loop counters can lead to unexpected behavior. | CORRECTNESS | FL_FLOATS_AS_LOOP_COUNTERS | 211 | Medium |
Exception is caught when Exception is not thrown in org.opentrafficsim.web.test.CircularRoadModel.constructModel() | STYLE | REC_CATCH_EXCEPTION | 223 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
new org.opentrafficsim.web.test.InputParameterHelper(InputParameterMap) may expose internal representation by storing an externally mutable object into InputParameterHelper.rootMap | MALICIOUS_CODE | EI_EXPOSE_REP2 | 41 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
Hard coded reference to an absolute pathname in org.opentrafficsim.web.test.TJunctionModel.constructModel() | STYLE | DMI_HARDCODED_ABSOLUTE_FILENAME | 57 | Medium |
org.opentrafficsim.web.test.TJunctionModel.getNetwork() may expose internal representation by returning TJunctionModel.network | MALICIOUS_CODE | EI_EXPOSE_REP | 122 | Medium |