CreateProcess error=206, The filename or extension is too long

匿名 (未验证) 提交于 2019-12-03 01:40:02

问题:

I'm trying to call Findbugs via Ant, but receiving this error:

Cannot run program "C:\Program Files (x86)\Java\jre6\bin\javaw.exe" (in  directory "H:\Users\MyName\workspace\MyProject"):  CreateProcess error=206, The filename or extension is too long 

How can I fix this? o.O

回答1:

I had the same problem. I used

inside findbugs target and it seems that there is too much .class files to be passed to findbug (?via command line?) because when I used

that had low number of classes, the error was gone.

So, I solved the problem by making one jar file and feeding it to findbugs target with

   ...   


回答2:

I think one of the effective file paths are really long when java tries to compile clases.

One worth try is to put codebase in a directory such as C:\MyProject instead of something like C:\Users\MyName\workspace\MyProject



标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!