FindBugs Bug Detector Report

The following document contains the results of FindBugs Report

FindBugs Version is 1.1.1

Threshold is Low

Effort is Default

Summary

ClassesBugsErrorsMissing Classes
424635855

Files

ClassBugs
org.microemu.app.Swt5
org.microemu.app.Swt$11
org.microemu.app.Swt$31
org.microemu.app.Swt$42
org.microemu.app.ui.swt.SwtDeviceComponent2
org.microemu.app.ui.swt.SwtDeviceComponent$CreateColorRunnable1
org.microemu.app.ui.swt.SwtDeviceComponent$CreateImageRunnable1
org.microemu.app.ui.swt.SwtDeviceComponent$GetFontMetricsRunnable1
org.microemu.app.ui.swt.SwtDeviceComponent$GetFontRunnable2
org.microemu.app.ui.swt.SwtDeviceComponent$StringWidthRunnable1
org.microemu.app.ui.swt.SwtDialog2
org.microemu.app.ui.swt.SwtGraphics1
org.microemu.app.ui.swt.SwtMessageDialog1
org.microemu.app.ui.swt.SwtSelectDeviceDialog$12
org.microemu.device.swt.BWImageFilter3
org.microemu.device.swt.GrayImageFilter6
org.microemu.device.swt.RGBImageFilter3
org.microemu.device.swt.SwtButton1
org.microemu.device.swt.SwtDeviceDisplay9
org.microemu.device.swt.SwtFontManager2
org.microemu.device.swt.SwtInputMethod2
org.microemu.device.swt.SwtSoftButton4
org.microemu.device.swt.SwtSystemFont3
org.microemu.device.swt.SwtTrueTypeFont7

org.microemu.app.Swt

BugCategoryDetailsLine
org.microemu.app.Swt.devicePanel should be package protectedMALICIOUS_CODEMS_PKGPROTECTNot available
org.microemu.app.Swt.shell should be package protectedMALICIOUS_CODEMS_PKGPROTECTNot available
Write to static field org.microemu.app.Swt.devicePanel from instance method org.microemu.app.Swt.initInterface(org.eclipse.swt.widgets.Shell)STYLEST_WRITE_TO_STATIC_FROM_INSTANCE_METHOD339
Useless control flow in org.microemu.app.Swt.setDevice(org.microemu.app.util.DeviceEntry)STYLEUCF_USELESS_CONTROL_FLOW350
Unread field: org.microemu.app.Swt.deviceEntryPERFORMANCEURF_UNREAD_FIELDNot available

org.microemu.app.Swt$1

BugCategoryDetailsLine
The class org.microemu.app.Swt$1 could be refactored into a named _static_ inner classPERFORMANCESIC_INNER_SHOULD_BE_STATIC_ANONNot available

org.microemu.app.Swt$3

BugCategoryDetailsLine
The class org.microemu.app.Swt$3 could be refactored into a named _static_ inner classPERFORMANCESIC_INNER_SHOULD_BE_STATIC_ANONNot available

org.microemu.app.Swt$4

BugCategoryDetailsLine
org.microemu.app.Swt$4.handleEvent(org.eclipse.swt.widgets.Event) invokes System.exit(...), which shuts down the entire virtual machineBAD_PRACTICEDM_EXIT155
The class org.microemu.app.Swt$4 could be refactored into a named _static_ inner classPERFORMANCESIC_INNER_SHOULD_BE_STATIC_ANONNot available

org.microemu.app.ui.swt.SwtDeviceComponent

BugCategoryDetailsLine
Write to static field org.microemu.app.ui.swt.SwtDeviceComponent.instance from instance method org.microemu.app.ui.swt.SwtDeviceComponent.SwtDeviceComponent(org.eclipse.swt.widgets.Composite)STYLEST_WRITE_TO_STATIC_FROM_INSTANCE_METHOD326
Useless control flow in org.microemu.app.ui.swt.SwtDeviceComponent.drawImageInShape(SwtGraphics,org.eclipse.swt.graphics.Image,org.microemu.device.impl.Shape)STYLEUCF_USELESS_CONTROL_FLOW456

org.microemu.app.ui.swt.SwtDeviceComponent$CreateColorRunnable

BugCategoryDetailsLine
Should org.microemu.app.ui.swt.SwtDeviceComponent$CreateColorRunnable be a _static_ inner class?PERFORMANCESIC_INNER_SHOULD_BE_STATICNot available

org.microemu.app.ui.swt.SwtDeviceComponent$CreateImageRunnable

BugCategoryDetailsLine
Should org.microemu.app.ui.swt.SwtDeviceComponent$CreateImageRunnable be a _static_ inner class?PERFORMANCESIC_INNER_SHOULD_BE_STATICNot available

org.microemu.app.ui.swt.SwtDeviceComponent$GetFontMetricsRunnable

BugCategoryDetailsLine
Should org.microemu.app.ui.swt.SwtDeviceComponent$GetFontMetricsRunnable be a _static_ inner class?PERFORMANCESIC_INNER_SHOULD_BE_STATICNot available

org.microemu.app.ui.swt.SwtDeviceComponent$GetFontRunnable

BugCategoryDetailsLine
Should org.microemu.app.ui.swt.SwtDeviceComponent$GetFontRunnable be a _static_ inner class?PERFORMANCESIC_INNER_SHOULD_BE_STATICNot available
Unwritten field: org.microemu.app.ui.swt.SwtDeviceComponent$GetFontRunnable.antialiasingCORRECTNESSUWF_UNWRITTEN_FIELDNot available

org.microemu.app.ui.swt.SwtDeviceComponent$StringWidthRunnable

BugCategoryDetailsLine
Should org.microemu.app.ui.swt.SwtDeviceComponent$StringWidthRunnable be a _static_ inner class?PERFORMANCESIC_INNER_SHOULD_BE_STATICNot available

org.microemu.app.ui.swt.SwtDialog

BugCategoryDetailsLine
Unread field: org.microemu.app.ui.swt.SwtDialog.contentsPERFORMANCEURF_UNREAD_FIELDNot available
Field not initialized in constructor: org.microemu.app.ui.swt.SwtDialog.shellSTYLEUWF_FIELD_NOT_INITIALIZED_IN_CONSTRUCTORNot available

org.microemu.app.ui.swt.SwtGraphics

BugCategoryDetailsLine
Confusing to have methods org.microemu.app.ui.swt.SwtGraphics.setFont(org.eclipse.swt.graphics.Font) and org.microemu.device.swt.SwtDisplayGraphics.setFont(javax.microedition.lcdui.Font)BAD_PRACTICENM_CONFUSING114-115

org.microemu.app.ui.swt.SwtMessageDialog

BugCategoryDetailsLine
org.microemu.app.ui.swt.SwtMessageDialog.SwtMessageDialog(org.eclipse.swt.widgets.Shell,String,String,int,String[],int) may expose internal representation by storing an externally mutable object into org.microemu.app.ui.swt.SwtMessageDialog.buttonLabelsMALICIOUS_CODEEI_EXPOSE_REP253

org.microemu.app.ui.swt.SwtSelectDeviceDialog$1

BugCategoryDetailsLine
Method org.microemu.app.ui.swt.SwtSelectDeviceDialog$1.handleEvent(org.eclipse.swt.widgets.Event) invokes dubious String.toUpperCase() or String.toLowerCase; use the Locale parameterized version insteadI18NDM_CONVERT_CASE103
Method org.microemu.app.ui.swt.SwtSelectDeviceDialog$1.handleEvent(org.eclipse.swt.widgets.Event) makes inefficient use of keySet iterator instead of entrySet iteratorPERFORMANCEWMI_WRONG_MAP_ITERATOR158

org.microemu.device.swt.BWImageFilter

BugCategoryDetailsLine
The field name org.microemu.device.swt.BWImageFilter.Yb doesn't start with an lower case letterBAD_PRACTICENM_FIELD_NAMING_CONVENTIONNot available
The field name org.microemu.device.swt.BWImageFilter.Yg doesn't start with an lower case letterBAD_PRACTICENM_FIELD_NAMING_CONVENTIONNot available
The field name org.microemu.device.swt.BWImageFilter.Yr doesn't start with an lower case letterBAD_PRACTICENM_FIELD_NAMING_CONVENTIONNot available

org.microemu.device.swt.GrayImageFilter

BugCategoryDetailsLine
The field name org.microemu.device.swt.GrayImageFilter.Rb doesn't start with an lower case letterBAD_PRACTICENM_FIELD_NAMING_CONVENTIONNot available
The field name org.microemu.device.swt.GrayImageFilter.Rg doesn't start with an lower case letterBAD_PRACTICENM_FIELD_NAMING_CONVENTIONNot available
The field name org.microemu.device.swt.GrayImageFilter.Rr doesn't start with an lower case letterBAD_PRACTICENM_FIELD_NAMING_CONVENTIONNot available
The field name org.microemu.device.swt.GrayImageFilter.Yb doesn't start with an lower case letterBAD_PRACTICENM_FIELD_NAMING_CONVENTIONNot available
The field name org.microemu.device.swt.GrayImageFilter.Yg doesn't start with an lower case letterBAD_PRACTICENM_FIELD_NAMING_CONVENTIONNot available
The field name org.microemu.device.swt.GrayImageFilter.Yr doesn't start with an lower case letterBAD_PRACTICENM_FIELD_NAMING_CONVENTIONNot available

org.microemu.device.swt.RGBImageFilter

BugCategoryDetailsLine
The field name org.microemu.device.swt.RGBImageFilter.Rb doesn't start with an lower case letterBAD_PRACTICENM_FIELD_NAMING_CONVENTIONNot available
The field name org.microemu.device.swt.RGBImageFilter.Rg doesn't start with an lower case letterBAD_PRACTICENM_FIELD_NAMING_CONVENTIONNot available
The field name org.microemu.device.swt.RGBImageFilter.Rr doesn't start with an lower case letterBAD_PRACTICENM_FIELD_NAMING_CONVENTIONNot available

org.microemu.device.swt.SwtButton

BugCategoryDetailsLine
org.microemu.device.swt.SwtButton.SwtButton(String,org.microemu.device.impl.Shape,int,String,java.util.Hashtable) may expose internal representation by storing an externally mutable object into org.microemu.device.swt.SwtButton.inputToCharsMALICIOUS_CODEEI_EXPOSE_REP265

org.microemu.device.swt.SwtDeviceDisplay

BugCategoryDetailsLine
Dead store to filter in method org.microemu.device.swt.SwtDeviceDisplay.createRGBImage(int[],int,int,boolean)STYLEDLS_DEAD_LOCAL_STORE510
Usage of GetResource in org.microemu.device.swt.SwtDeviceDisplay.getImage(String) may be unsafe if class is extendedBAD_PRACTICEUI_INHERITANCE_UNSAFE_GETRESOURCE430
Field not initialized in constructor: org.microemu.device.swt.SwtDeviceDisplay.backgroundColorSTYLEUWF_FIELD_NOT_INITIALIZED_IN_CONSTRUCTORNot available
Field not initialized in constructor: org.microemu.device.swt.SwtDeviceDisplay.displayPaintableSTYLEUWF_FIELD_NOT_INITIALIZED_IN_CONSTRUCTORNot available
Field not initialized in constructor: org.microemu.device.swt.SwtDeviceDisplay.displayRectangleSTYLEUWF_FIELD_NOT_INITIALIZED_IN_CONSTRUCTORNot available
Field not initialized in constructor: org.microemu.device.swt.SwtDeviceDisplay.foregroundColorSTYLEUWF_FIELD_NOT_INITIALIZED_IN_CONSTRUCTORNot available
Field not initialized in constructor: org.microemu.device.swt.SwtDeviceDisplay.mode123ImageSTYLEUWF_FIELD_NOT_INITIALIZED_IN_CONSTRUCTORNot available
Field not initialized in constructor: org.microemu.device.swt.SwtDeviceDisplay.modeAbcLowerImageSTYLEUWF_FIELD_NOT_INITIALIZED_IN_CONSTRUCTORNot available
Field not initialized in constructor: org.microemu.device.swt.SwtDeviceDisplay.modeAbcUpperImageSTYLEUWF_FIELD_NOT_INITIALIZED_IN_CONSTRUCTORNot available

org.microemu.device.swt.SwtFontManager

BugCategoryDetailsLine
Incompatible bit masks yield a constant result in org.microemu.device.swt.SwtFontManager.getFont(javax.microedition.lcdui.Font)CORRECTNESSBIT_AND_ZZ68
Method org.microemu.device.swt.SwtFontManager.setFont(String,String,String,org.microemu.device.impl.Font) invokes dubious String.toUpperCase() or String.toLowerCase; use the Locale parameterized version insteadI18NDM_CONVERT_CASE146

org.microemu.device.swt.SwtInputMethod

BugCategoryDetailsLine
Method org.microemu.device.swt.SwtInputMethod.keyPressed(org.eclipse.swt.events.KeyEvent) allocates a boxed primitive just to call toStringPERFORMANCEDM_BOXED_PRIMITIVE_TOSTRING336
Using notify rather than notifyAll in org.microemu.device.swt.SwtInputMethod.mousePressed(org.eclipse.swt.events.KeyEvent)MT_CORRECTNESSNO_NOTIFY_NOT_NOTIFYALL418

org.microemu.device.swt.SwtSoftButton

BugCategoryDetailsLine
Inconsistent synchronization of org.microemu.device.swt.SwtSoftButton.command; locked % of timeMT_CORRECTNESSIS2_INCONSISTENT_SYNC137
org.microemu.device.swt.SwtSoftButton.LEFT isn't final but should beMALICIOUS_CODEMS_SHOULD_BE_FINAL40
org.microemu.device.swt.SwtSoftButton.RIGHT isn't final but should beMALICIOUS_CODEMS_SHOULD_BE_FINAL41
Method org.microemu.device.swt.SwtSoftButton.SwtSoftButton(String,org.microemu.device.impl.Shape,int,String,org.microemu.device.impl.Rectangle,String,java.util.Vector,javax.microedition.lcdui.Font) catches Exception, but Exception is not thrown in the try block and RuntimeException is not explicitly caughtSTYLEREC_CATCH_EXCEPTION86

org.microemu.device.swt.SwtSystemFont

BugCategoryDetailsLine
Method org.microemu.device.swt.SwtSystemFont.SwtSystemFont(String,String,int,boolean) invokes dubious String.toUpperCase() or String.toLowerCase; use the Locale parameterized version insteadI18NDM_CONVERT_CASE42
Inconsistent synchronization of org.microemu.device.swt.SwtSystemFont.initialized; locked % of timeMT_CORRECTNESSIS2_INCONSISTENT_SYNC52
Useless control flow in org.microemu.device.swt.SwtSystemFont.checkInitialized()STYLEUCF_USELESS_CONTROL_FLOW74

org.microemu.device.swt.SwtTrueTypeFont

BugCategoryDetailsLine
Dead store to swtStyle in method org.microemu.device.swt.SwtTrueTypeFont.checkInitialized()STYLEDLS_DEAD_LOCAL_STORE73
Method org.microemu.device.swt.SwtTrueTypeFont.SwtTrueTypeFont(java.net.URL,String,int,boolean) invokes dubious String.toUpperCase() or String.toLowerCase; use the Locale parameterized version insteadI18NDM_CONVERT_CASE43
Inconsistent synchronization of org.microemu.device.swt.SwtTrueTypeFont.initialized; locked % of timeMT_CORRECTNESSIS2_INCONSISTENT_SYNC53
Useless control flow in org.microemu.device.swt.SwtTrueTypeFont.checkInitialized()STYLEUCF_USELESS_CONTROL_FLOW75
Unread field: org.microemu.device.swt.SwtTrueTypeFont.sizePERFORMANCEURF_UNREAD_FIELDNot available
Unread field: org.microemu.device.swt.SwtTrueTypeFont.urlPERFORMANCEURF_UNREAD_FIELDNot available
Unwritten field: org.microemu.device.swt.SwtTrueTypeFont.fontCORRECTNESSUWF_UNWRITTEN_FIELDNot available