简体   繁体   中英

Findbugs in eclipse-Indigo giving error “java.lang.ArrayIndexOutOfBoundsException”

im trying to use findbugs on my application, which has JRE1.7 and compliance level 1.7, when i use Find bugs i get following error

java.lang.ArrayIndexOutOfBoundsException: 19567
at org.objectweb.asm.ClassReader.accept(Unknown Source)
at edu.umd.cs.findbugs.asm.FBClassReader.accept(FBClassReader.java:44)
at org.objectweb.asm.ClassReader.accept(Unknown Source)
at edu.umd.cs.findbugs.classfile.engine.ClassParserUsingASM.parse(ClassParserUsingASM.java:110)
at edu.umd.cs.findbugs.classfile.engine.ClassParserUsingASM.parse(ClassParserUsingASM.java:554)
at edu.umd.cs.findbugs.classfile.engine.ClassInfoAnalysisEngine.analyze(ClassInfoAnalysisEngine.java:76)
at edu.umd.cs.findbugs.classfile.engine.ClassInfoAnalysisEngine.analyze(ClassInfoAnalysisEngine.java:38)
at edu.umd.cs.findbugs.classfile.impl.AnalysisCache.getClassAnalysis(AnalysisCache.java:266)
at edu.umd.cs.findbugs.ba.XFactory.getXClass(XFactory.java:652)
at edu.umd.cs.findbugs.ba.ch.Subtypes2.addInheritanceEdge(Subtypes2.java:1227)
at edu.umd.cs.findbugs.ba.ch.Subtypes2.addSupertypeEdges(Subtypes2.java:1200)
at edu.umd.cs.findbugs.ba.ch.Subtypes2.addClassAndGetClassVertex(Subtypes2.java:275)
at edu.umd.cs.findbugs.ba.ch.Subtypes2.addClass(Subtypes2.java:244)
at edu.umd.cs.findbugs.ba.AnalysisCacheToAnalysisContextAdapter.setAppClassList(AnalysisCacheToAnalysisContextAdapter.java:400)
at edu.umd.cs.findbugs.FindBugs2.setAppClassList(FindBugs2.java:982)
at edu.umd.cs.findbugs.FindBugs2.execute(FindBugs2.java:225)
at de.tobject.findbugs.builder.FindBugsWorker.runFindBugs(FindBugsWorker.java:314)
at de.tobject.findbugs.builder.FindBugsWorker.work(FindBugsWorker.java:222)
at de.tobject.findbugs.actions.FindBugsAction$StartedFromViewJob.runWithProgress(FindBugsAction.java:265)
at de.tobject.findbugs.FindBugsJob.run(FindBugsJob.java:102)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54)

also Session Data

eclipse.buildId=M20110909-1335
java.version=1.8.0_20
java.vendor=Oracle Corporation
BootLoader constants: OS=win32, ARCH=x86, WS=win32, NL=en_US
Framework arguments:  -product org.eclipse.epp.package.jee.product
Command-line arguments:  -os win32 -ws win32 -arch x86 -product 
 org.eclipse.epp.package.jee.product

i googled about it, i says that find bug v2.x is not comaptble with java8 but im using java 7

after the whole day search.. i was finally able to solve this problem.. first of all findbugs do not wrk with java 8 .. that is right.

soo even when u have java7 fr ur projects. please check if you have java8 installed on ur system.. because if u do.. den edit..eclipse.ini file.. with following code.

-vm
 C:\Program Files (x86)\Java\jdk1.7.0_45\jre\bin\client\jvm.dll

put dese lines just before -vmargs change path acc and den it should wrk perfectly.. it happens coz eclipse create a VM itself.. and that too with latest java and plugins use this VM

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM