dcsimg
Another problem with System.exit()
0 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Alexey_Demakov
Posted On:   Friday, December 20, 2002 10:11 AM

When ANTLR run from maven build system, maven's NoExitSecurityManager catches System.exit(code)
calls and throws java.lang.SecurityException
with code in message to prevent JVM finish.

It works fine with System.exit(0) at the and of antlr.Tool.main(). But there is another System.exit(0) call - at the end of antlr.Tool.doEverything().
main() catches exception produced by NoExitSecurityManager
and prints message about internal error!


Should I subclass antlr.Tool to write my own main method
or System.exit(0) at the end of doEverything() is unnecessary and will be removed in future versions?

About | Sitemap | Contact