简体   繁体   中英

jdb not recognizing '--add-reads' option

I'm working on a project where an invocation of a java file is returning a NullPointerException, but I'm not getting any clues as to why, so I'd like to run it through jdb. According to to this page, I should be able to simply replace the call to java with jdb , but when I do, I'm getting the error:

/auto/tools/java/jdk-14.0.1/bin/jdb --add-reads stringtemplate=foostring  -p ./tools/foo:./tools/bar -m foo/com.bar.foo.FOO  -tp ./bar/ -p -o bin/foo -i foo.in

invalid option: --add-reads

Is there a trick I'm missing to allow me to pass all these options to jdb?

Java commands (java, javac, jdb) do not use the GNU double-dash convention. Use a single dash.

Or if that's an option for the program itself, it should probably come after the class name.

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