SpotBugs Bug Detector Report
The following document contains the results of SpotBugs
SpotBugs Version is 4.3.0
Threshold is medium
Effort is default
Summary
Classes |
Bugs |
Errors |
Missing Classes |
119 |
38 |
0 |
0 |
org.eclipse.jgit.pgm.Archive
Bug |
Category |
Details |
Line |
Priority |
org.eclipse.jgit.pgm.Archive.run() may fail to clean up java.io.OutputStream |
EXPERIMENTAL |
OBL_UNSATISFIED_OBLIGATION |
53 |
Medium |
org.eclipse.jgit.pgm.DiffTool
Bug |
Category |
Details |
Line |
Priority |
Return value of TextBuiltin.die(String) ignored, but method has no side effect |
STYLE |
RV_RETURN_VALUE_IGNORED_NO_SIDE_EFFECT |
305 |
Medium |
org.eclipse.jgit.pgm.DiffTool.showToolHelp() makes inefficient use of keySet iterator instead of entrySet iterator |
PERFORMANCE |
WMI_WRONG_MAP_ITERATOR |
279 |
Medium |
org.eclipse.jgit.pgm.MergeTool
Bug |
Category |
Details |
Line |
Priority |
Dead store to files in org.eclipse.jgit.pgm.MergeTool.getFiles() |
STYLE |
DLS_DEAD_LOCAL_STORE |
469 |
Medium |
Switch statement found in org.eclipse.jgit.pgm.MergeTool.mergeModified(String, boolean) where default case is missing |
STYLE |
SF_SWITCH_NO_DEFAULT |
250-269 |
Medium |
org.eclipse.jgit.pgm.MergeTool.showToolHelp() makes inefficient use of keySet iterator instead of entrySet iterator |
PERFORMANCE |
WMI_WRONG_MAP_ITERATOR |
449 |
Medium |
org.eclipse.jgit.pgm.TextBuiltin
Bug |
Category |
Details |
Line |
Priority |
org.eclipse.jgit.pgm.TextBuiltin.getErrorWriter() may expose internal representation by returning TextBuiltin.errw |
MALICIOUS_CODE |
EI_EXPOSE_REP |
331 |
Medium |
org.eclipse.jgit.pgm.TextBuiltin.getOutputWriter() may expose internal representation by returning TextBuiltin.outw |
MALICIOUS_CODE |
EI_EXPOSE_REP |
341 |
Medium |
org.eclipse.jgit.pgm.TextBuiltin.getRepository() may expose internal representation by returning TextBuiltin.db |
MALICIOUS_CODE |
EI_EXPOSE_REP |
372 |
Medium |
org.eclipse.jgit.pgm.TextBuiltin.initRaw(Repository, String, InputStream, OutputStream, OutputStream) may expose internal representation by storing an externally mutable object into TextBuiltin.errs |
MALICIOUS_CODE |
EI_EXPOSE_REP2 |
146 |
Medium |
org.eclipse.jgit.pgm.TextBuiltin.initRaw(Repository, String, InputStream, OutputStream, OutputStream) may expose internal representation by storing an externally mutable object into TextBuiltin.outs |
MALICIOUS_CODE |
EI_EXPOSE_REP2 |
145 |
Medium |
org.eclipse.jgit.pgm.debug.DiffAlgorithms
Bug |
Category |
Details |
Line |
Priority |
Format string should use %n rather than \n in org.eclipse.jgit.pgm.debug.DiffAlgorithms.run(Repository) |
BAD_PRACTICE |
VA_FORMAT_STRING_USES_NEWLINE |
221 |
Medium |
Format string should use %n rather than \n in org.eclipse.jgit.pgm.debug.DiffAlgorithms.run(Repository) |
BAD_PRACTICE |
VA_FORMAT_STRING_USES_NEWLINE |
223 |
Medium |
Format string should use %n rather than \n in org.eclipse.jgit.pgm.debug.DiffAlgorithms.run(Repository) |
BAD_PRACTICE |
VA_FORMAT_STRING_USES_NEWLINE |
226 |
Medium |
Format string should use %n rather than \n in org.eclipse.jgit.pgm.debug.DiffAlgorithms.run(Repository) |
BAD_PRACTICE |
VA_FORMAT_STRING_USES_NEWLINE |
228 |
Medium |
org.eclipse.jgit.pgm.debug.LfsStore
Bug |
Category |
Details |
Line |
Priority |
Return value of org.eclipse.jgit.pgm.TextBuiltin.die(String) ignored, but method has no side effect |
STYLE |
RV_RETURN_VALUE_IGNORED_NO_SIDE_EFFECT |
275 |
Medium |
org.eclipse.jgit.pgm.debug.TextHashFunctions
Bug |
Category |
Details |
Line |
Priority |
Format string should use %n rather than \n in org.eclipse.jgit.pgm.debug.TextHashFunctions.run(Repository) |
BAD_PRACTICE |
VA_FORMAT_STRING_USES_NEWLINE |
317 |
Medium |
Format string should use %n rather than \n in org.eclipse.jgit.pgm.debug.TextHashFunctions.run(Repository) |
BAD_PRACTICE |
VA_FORMAT_STRING_USES_NEWLINE |
327 |
Medium |
Format string should use %n rather than \n in org.eclipse.jgit.pgm.debug.TextHashFunctions.run(Repository) |
BAD_PRACTICE |
VA_FORMAT_STRING_USES_NEWLINE |
320 |
Medium |
org.eclipse.jgit.pgm.opt.AbstractTreeIteratorHandler
Bug |
Category |
Details |
Line |
Priority |
Unchecked/unconfirmed cast from org.kohsuke.args4j.CmdLineParser to org.eclipse.jgit.pgm.opt.CmdLineParser in new org.eclipse.jgit.pgm.opt.AbstractTreeIteratorHandler(CmdLineParser, OptionDef, Setter) |
STYLE |
BC_UNCONFIRMED_CAST |
63 |
Medium |
new org.eclipse.jgit.pgm.opt.AbstractTreeIteratorHandler(CmdLineParser, OptionDef, Setter) may expose internal representation by storing an externally mutable object into AbstractTreeIteratorHandler.clp |
MALICIOUS_CODE |
EI_EXPOSE_REP2 |
63 |
Medium |
org.eclipse.jgit.pgm.opt.CmdLineParser
Bug |
Category |
Details |
Line |
Priority |
org.eclipse.jgit.pgm.opt.CmdLineParser.getRepository() may expose internal representation by returning CmdLineParser.db |
MALICIOUS_CODE |
EI_EXPOSE_REP |
214 |
Medium |
org.eclipse.jgit.pgm.opt.CmdLineParser.getRevWalk() may expose internal representation by returning CmdLineParser.walk |
MALICIOUS_CODE |
EI_EXPOSE_REP |
225 |
Medium |
org.eclipse.jgit.pgm.opt.CmdLineParser.getRevWalkGently() may expose internal representation by returning CmdLineParser.walk |
MALICIOUS_CODE |
EI_EXPOSE_REP |
236 |
Medium |
new org.eclipse.jgit.pgm.opt.CmdLineParser(Object, Repository) may expose internal representation by storing an externally mutable object into CmdLineParser.cmd |
MALICIOUS_CODE |
EI_EXPOSE_REP2 |
103 |
Medium |
The class name org.eclipse.jgit.pgm.opt.CmdLineParser shadows the simple name of the superclass org.kohsuke.args4j.CmdLineParser |
BAD_PRACTICE |
NM_SAME_SIMPLE_NAME_AS_SUPERCLASS |
50-307 |
High |
org.eclipse.jgit.pgm.opt.ObjectIdHandler
Bug |
Category |
Details |
Line |
Priority |
Unchecked/unconfirmed cast from org.kohsuke.args4j.CmdLineParser to org.eclipse.jgit.pgm.opt.CmdLineParser in new org.eclipse.jgit.pgm.opt.ObjectIdHandler(CmdLineParser, OptionDef, Setter) |
STYLE |
BC_UNCONFIRMED_CAST |
49 |
Medium |
new org.eclipse.jgit.pgm.opt.ObjectIdHandler(CmdLineParser, OptionDef, Setter) may expose internal representation by storing an externally mutable object into ObjectIdHandler.clp |
MALICIOUS_CODE |
EI_EXPOSE_REP2 |
49 |
Medium |
org.eclipse.jgit.pgm.opt.RevCommitHandler
Bug |
Category |
Details |
Line |
Priority |
Unchecked/unconfirmed cast from org.kohsuke.args4j.CmdLineParser to org.eclipse.jgit.pgm.opt.CmdLineParser in new org.eclipse.jgit.pgm.opt.RevCommitHandler(CmdLineParser, OptionDef, Setter) |
STYLE |
BC_UNCONFIRMED_CAST |
53 |
Medium |
new org.eclipse.jgit.pgm.opt.RevCommitHandler(CmdLineParser, OptionDef, Setter) may expose internal representation by storing an externally mutable object into RevCommitHandler.clp |
MALICIOUS_CODE |
EI_EXPOSE_REP2 |
53 |
Medium |
org.eclipse.jgit.pgm.opt.RevTreeHandler
Bug |
Category |
Details |
Line |
Priority |
Unchecked/unconfirmed cast from org.kohsuke.args4j.CmdLineParser to org.eclipse.jgit.pgm.opt.CmdLineParser in new org.eclipse.jgit.pgm.opt.RevTreeHandler(CmdLineParser, OptionDef, Setter) |
STYLE |
BC_UNCONFIRMED_CAST |
52 |
Medium |
new org.eclipse.jgit.pgm.opt.RevTreeHandler(CmdLineParser, OptionDef, Setter) may expose internal representation by storing an externally mutable object into RevTreeHandler.clp |
MALICIOUS_CODE |
EI_EXPOSE_REP2 |
52 |
Medium |
org.eclipse.jgit.pgm.opt.SubcommandHandler
Bug |
Category |
Details |
Line |
Priority |
Unchecked/unconfirmed cast from org.kohsuke.args4j.CmdLineParser to org.eclipse.jgit.pgm.opt.CmdLineParser in new org.eclipse.jgit.pgm.opt.SubcommandHandler(CmdLineParser, OptionDef, Setter) |
STYLE |
BC_UNCONFIRMED_CAST |
49 |
Medium |
new org.eclipse.jgit.pgm.opt.SubcommandHandler(CmdLineParser, OptionDef, Setter) may expose internal representation by storing an externally mutable object into SubcommandHandler.clp |
MALICIOUS_CODE |
EI_EXPOSE_REP2 |
49 |
Medium |