FindBugs Bug Detector Report

The following document contains the results of FindBugs Report

FindBugs Version is 1.2.0

Threshold is Low

Effort is Default

Summary

ClassesBugsErrorsMissing Classes
4827500

Files

ClassBugs
com.barteo.emulator.device.Device2
nanoxml.XMLElement13
org.microemu.app.Common9
org.microemu.app.Common$13
org.microemu.app.Config4
org.microemu.app.classloader.ClassPreprocessor1
org.microemu.app.classloader.MIDletClassLoader5
org.microemu.app.classloader.MIDletClassLoader$21
org.microemu.app.util.DeviceEntry2
org.microemu.app.util.FileRecordStoreManager4
org.microemu.app.util.FileRecordStoreManager$11
org.microemu.app.util.MIDletResourceLoader2
org.microemu.app.util.MIDletSystemProperties1
org.microemu.app.util.MIDletThread2
org.microemu.app.util.MidletURLReference1
org.microemu.app.util.ResURLStreamHandler1
org.microemu.cldc.datagram.Connection1
org.microemu.cldc.datagram.DatagramImpl1
org.microemu.cldc.http.Connection2
org.microemu.cldc.ssl.Connection$12
org.microemu.device.impl.ButtonName1
org.microemu.device.impl.DeviceImpl5
org.microemu.device.impl.InputMethodImpl7
org.microemu.device.impl.Polygon2
org.microemu.log.StdOutAppender1
org.microemu.microedition.io.ConnectorImpl1

com.barteo.emulator.device.Device

BugCategoryDetailsLine
VERY confusing to have methods com.barteo.emulator.device.Device.init(EmulatorContext, String) and org.microemu.device.impl.DeviceImpl.init(EmulatorContext, String)CORRECTNESSNM_VERY_CONFUSING42-43
VERY confusing to have methods com.barteo.emulator.device.Device.init(EmulatorContext) and org.microemu.device.impl.DeviceImpl.init(EmulatorContext)CORRECTNESSNM_VERY_CONFUSING35-36

nanoxml.XMLElement

BugCategoryDetailsLine
Use of non-localized String.toUpperCase() or String.toLowerCaseI18NDM_CONVERT_CASE1184
Use of non-localized String.toUpperCase() or String.toLowerCaseI18NDM_CONVERT_CASE1241
Use of non-localized String.toUpperCase() or String.toLowerCaseI18NDM_CONVERT_CASE1746
Use of non-localized String.toUpperCase() or String.toLowerCaseI18NDM_CONVERT_CASE1613
Use of non-localized String.toUpperCase() or String.toLowerCaseI18NDM_CONVERT_CASE1675
Use of non-localized String.toUpperCase() or String.toLowerCaseI18NDM_CONVERT_CASE1457
Use of non-localized String.toUpperCase() or String.toLowerCaseI18NDM_CONVERT_CASE1518
Use of non-localized String.toUpperCase() or String.toLowerCaseI18NDM_CONVERT_CASE2362
Use of non-localized String.toUpperCase() or String.toLowerCaseI18NDM_CONVERT_CASE693
Use of non-localized String.toUpperCase() or String.toLowerCaseI18NDM_CONVERT_CASE829
Use of non-localized String.toUpperCase() or String.toLowerCaseI18NDM_CONVERT_CASE761
Comparison of String parameter using == or != in nanoxml.XMLElement.getChild(String, String) BAD_PRACTICEES_COMPARING_PARAMETER_STRING_WITH_EQ1024
Switch statement found in nanoxml.XMLElement.scanWhitespace(StringBuffer) where one case falls through to the next caseSTYLESF_SWITCH_FALLTHROUGH2738-2741

org.microemu.app.Common

BugCategoryDetailsLine
Use of non-localized String.toUpperCase() or String.toLowerCaseI18NDM_CONVERT_CASE737
org.microemu.app.Common.initParams(List, DeviceEntry, Class) invokes System.exit(...), which shuts down the entire virtual machineBAD_PRACTICEDM_EXIT698
org.microemu.app.Common.createExtensionsClassLoader(URL[]) creates a org.microemu.app.classloader.ExtensionsClassLoader classloader, which should be performed within a doPrivileged blockBAD_PRACTICEDP_CREATE_CLASSLOADER_INSIDE_DO_PRIVILEGED861
Redundant nullcheck of clConfig, which is known to be non-null in org.microemu.app.Common.initParams(List, DeviceEntry, Class)STYLERCN_REDUNDANT_NULLCHECK_OF_NONNULL_VALUE724
Write to static field org.microemu.app.Common.instance from instance method org.microemu.app.Common.Common(EmulatorContext)STYLEST_WRITE_TO_STATIC_FROM_INSTANCE_METHOD121
Write to static field org.microemu.app.Common.launcher from instance method org.microemu.app.Common.Common(EmulatorContext)STYLEST_WRITE_TO_STATIC_FROM_INSTANCE_METHOD125
Write to static field org.microemu.app.Common.statusBarListener from instance method org.microemu.app.Common.setStatusBarListener(StatusBarListener)STYLEST_WRITE_TO_STATIC_FROM_INSTANCE_METHOD442
Write to static field org.microemu.app.Common.launcher from instance method org.microemu.app.Common.startLauncher(MIDletContext)STYLEST_WRITE_TO_STATIC_FROM_INSTANCE_METHOD430
Common.mIDletClassLoaderConfig not initialized in constructorSTYLEUWF_FIELD_NOT_INITIALIZED_IN_CONSTRUCTORNot available

org.microemu.app.Common$1

BugCategoryDetailsLine
org.microemu.app.Common$1.run() invokes System.exit(...), which shuts down the entire virtual machineBAD_PRACTICEDM_EXIT312
Method org.microemu.app.Common$1.1(Common, String, Common, String, boolean) creates a thread using the default empty run methodMT_CORRECTNESSDM_USELESS_THREAD244
Unconditional wait in org.microemu.app.Common$1.run()MT_CORRECTNESSUW_UNCOND_WAIT293

org.microemu.app.Config

BugCategoryDetailsLine
Use of non-localized String.toUpperCase() or String.toLowerCaseI18NDM_CONVERT_CASE469
org.microemu.app.Config.loadConfigFile(String) may fail to close streamBAD_PRACTICEOS_OPEN_STREAM130
org.microemu.app.Config.loadConfigFile(String) ignores result of java.io.InputStream.read(byte[])BAD_PRACTICERR_NOT_CHECKED133
Method org.microemu.app.Config.loadConfigFile(String) concatenates strings using + in a loopPERFORMANCESBSC_USE_STRINGBUFFER_CONCATENATION134

org.microemu.app.classloader.ClassPreprocessor

BugCategoryDetailsLine
Should org.microemu.app.classloader.ClassPreprocessor.instrument(InputStream, InstrumentationConfig) return a zero length array rather than null?STYLEPZLA_PREFER_ZERO_LENGTH_ARRAYS47

org.microemu.app.classloader.MIDletClassLoader

BugCategoryDetailsLine
Dead store to maxClassSizeSize in org.microemu.app.classloader.MIDletClassLoader.findClass(String)STYLEDLS_DEAD_LOCAL_STORE375
org.microemu.app.classloader.MIDletClassLoader.enhanceCatchBlock isn't final but should beMALICIOUS_CODEMS_SHOULD_BE_FINAL61
org.microemu.app.classloader.MIDletClassLoader.instrumentMIDletClasses isn't final but should beMALICIOUS_CODEMS_SHOULD_BE_FINAL55
org.microemu.app.classloader.MIDletClassLoader.traceClassLoading isn't final but should beMALICIOUS_CODEMS_SHOULD_BE_FINAL57
org.microemu.app.classloader.MIDletClassLoader.traceSystemClassLoading isn't final but should beMALICIOUS_CODEMS_SHOULD_BE_FINAL59

org.microemu.app.classloader.MIDletClassLoader$2

BugCategoryDetailsLine
The class org.microemu.app.classloader.MIDletClassLoader$2 could be refactored into a named _static_ inner classPERFORMANCESIC_INNER_SHOULD_BE_STATIC_ANONNot available

org.microemu.app.util.DeviceEntry

BugCategoryDetailsLine
org.microemu.app.util.DeviceEntry defines equals(DeviceEntry) method and uses Object.equals(Object)BAD_PRACTICEEQ_SELF_USE_OBJECT134-141
org.microemu.app.util.DeviceEntry defines equals and uses Object.hashCode()BAD_PRACTICEHE_EQUALS_USE_HASHCODE134-141

org.microemu.app.util.FileRecordStoreManager

BugCategoryDetailsLine
Dead store to recordStoreImpl in org.microemu.app.util.FileRecordStoreManager.deleteRecordStore(String)STYLEDLS_DEAD_LOCAL_STORE94
org.microemu.app.util.FileRecordStoreManager.loadFromDiskSecure(File) may fail to close stream on exceptionBAD_PRACTICEOS_OPEN_STREAM_EXCEPTION_PATH203
org.microemu.app.util.FileRecordStoreManager.saveToDiskSecure(File, RecordStoreImpl) may fail to close stream on exceptionBAD_PRACTICEOS_OPEN_STREAM_EXCEPTION_PATH239
Should org.microemu.app.util.FileRecordStoreManager.listRecordStores() return a zero length array rather than null?STYLEPZLA_PREFER_ZERO_LENGTH_ARRAYS148

org.microemu.app.util.FileRecordStoreManager$1

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

org.microemu.app.util.MIDletResourceLoader

BugCategoryDetailsLine
org.microemu.app.util.MIDletResourceLoader.classLoader isn't final and can't be protected from malicious code MALICIOUS_CODEMS_CANNOT_BE_FINALNot available
org.microemu.app.util.MIDletResourceLoader.traceResourceLoading isn't final but should beMALICIOUS_CODEMS_SHOULD_BE_FINAL46

org.microemu.app.util.MIDletSystemProperties

BugCategoryDetailsLine
org.microemu.app.util.MIDletSystemProperties.applyToJavaSystemProperties isn't final but should beMALICIOUS_CODEMS_SHOULD_BE_FINAL50

org.microemu.app.util.MIDletThread

BugCategoryDetailsLine
Method org.microemu.app.util.MIDletThread.MIDletThread() creates a thread using the default empty run methodMT_CORRECTNESSDM_USELESS_THREAD57
org.microemu.app.util.MIDletThread.graceTerminationPeriod isn't final but should beMALICIOUS_CODEMS_SHOULD_BE_FINAL40

org.microemu.app.util.MidletURLReference

BugCategoryDetailsLine
org.microemu.app.util.MidletURLReference defines equals and uses Object.hashCode()BAD_PRACTICEHE_EQUALS_USE_HASHCODE59-62

org.microemu.app.util.ResURLStreamHandler

BugCategoryDetailsLine
org.microemu.app.util.ResURLStreamHandler.ResURLStreamHandler(Hashtable) may expose internal representation by storing an externally mutable object into ResURLStreamHandler.entriesMALICIOUS_CODEEI_EXPOSE_REP236

org.microemu.cldc.datagram.Connection

BugCategoryDetailsLine
Connection.socket not initialized in constructorSTYLEUWF_FIELD_NOT_INITIALIZED_IN_CONSTRUCTORNot available

org.microemu.cldc.datagram.DatagramImpl

BugCategoryDetailsLine
org.microemu.cldc.datagram.DatagramImpl.readFully(byte[], int, int) ignores result of java.io.DataInputStream.read(byte[], int, int)BAD_PRACTICERR_NOT_CHECKED203

org.microemu.cldc.http.Connection

BugCategoryDetailsLine
org.microemu.cldc.http.Connection.allowNetworkConnection should be package protectedMALICIOUS_CODEMS_PKGPROTECT42
Confusing to have methods org.microemu.cldc.http.Connection.getURL() and org.microemu.app.util.MidletURLReference.getUrl()BAD_PRACTICENM_CONFUSING73-77

org.microemu.cldc.ssl.Connection$1

BugCategoryDetailsLine
Should org.microemu.cldc.ssl.Connection$1.getAcceptedIssuers() return a zero length array rather than null?STYLEPZLA_PREFER_ZERO_LENGTH_ARRAYS64
The class org.microemu.cldc.ssl.Connection$1 could be refactored into a named _static_ inner classPERFORMANCESIC_INNER_SHOULD_BE_STATIC_ANONNot available

org.microemu.device.impl.ButtonName

BugCategoryDetailsLine
Use of non-localized String.toUpperCase() or String.toLowerCaseI18NDM_CONVERT_CASE92

org.microemu.device.impl.DeviceImpl

BugCategoryDetailsLine
Use of non-localized String.toUpperCase() or String.toLowerCaseI18NDM_CONVERT_CASE579
Use of non-localized String.toUpperCase() or String.toLowerCaseI18NDM_CONVERT_CASE639
Use of non-localized String.toUpperCase() or String.toLowerCaseI18NDM_CONVERT_CASE444
org.microemu.device.impl.DeviceImpl.parseBoolean(String) invokes inefficient new String(String) constructorPERFORMANCEDM_STRING_CTOR639
Private method org.microemu.device.impl.DeviceImpl.saveDevice(XMLElement) is never calledPERFORMANCEUPM_UNCALLED_PRIVATE_METHOD692-703

org.microemu.device.impl.InputMethodImpl

BugCategoryDetailsLine
Method org.microemu.device.impl.InputMethodImpl.filterConstraints(char[]) uses the same code for two switch clausesSTYLEDB_DUPLICATE_SWITCH_CLAUSES151
Inconsistent synchronization of org.microemu.device.impl.InputMethodImpl.lastButton; locked 66% of timeMT_CORRECTNESSIS2_INCONSISTENT_SYNC88
Inconsistent synchronization of org.microemu.device.impl.InputMethodImpl.resetKey; locked 50% of timeMT_CORRECTNESSIS2_INCONSISTENT_SYNC65
Naked notify in org.microemu.device.impl.InputMethodImpl.dispose()MT_CORRECTNESSNN_NAKED_NOTIFY56
Using notify rather than notifyAll in org.microemu.device.impl.InputMethodImpl.dispose()MT_CORRECTNESSNO_NOTIFY_NOT_NOTIFYALL56
org.microemu.device.impl.InputMethodImpl.InputMethodImpl() invokes java.lang.Thread.start()MT_CORRECTNESSSC_START_IN_CTOR49
Unconditional wait in org.microemu.device.impl.InputMethodImpl.run()MT_CORRECTNESSUW_UNCOND_WAIT67

org.microemu.device.impl.Polygon

BugCategoryDetailsLine
Dead store of null to xtemp in org.microemu.device.impl.Polygon.addPoint(int, int)STYLEDLS_DEAD_LOCAL_STORE_OF_NULL105
Dead store of null to ytemp in org.microemu.device.impl.Polygon.addPoint(int, int)STYLEDLS_DEAD_LOCAL_STORE_OF_NULL108

org.microemu.log.StdOutAppender

BugCategoryDetailsLine
org.microemu.log.StdOutAppender.enabled isn't final but should beMALICIOUS_CODEMS_SHOULD_BE_FINAL32

org.microemu.microedition.io.ConnectorImpl

BugCategoryDetailsLine
org.microemu.microedition.io.ConnectorImpl.debugConnectionInvocations isn't final but should beMALICIOUS_CODEMS_SHOULD_BE_FINAL52