Jaroslav, Command line processing is still not clean, e.g. you check for -help in three different places.
If you go to refactor this code rather than provide a minimal fix, it might be better to create a separate inner class that do all command line processing and provide couple of flags like should_sa(), should_help(), should_attach() etc. -Dmitry On 2014-04-03 15:27, Jaroslav Bachorik wrote: > Please, review the following fix in "jinfo" launcher. > > Issue : https://bugs.openjdk.java.net/browse/JDK-8039080 > Webrev: http://cr.openjdk.java.net/~jbachorik/8039080/webrev.00 > > When switching "jinfo" to utilize diagnostic commands when possible a > combination of launcher arguments was omitted causing "jinfo" fail to > execute the default action (-flags & -sysproperties) against a remote SA > debug server. > > The patch fixes this omission. Additionally it contains a refactoring to > make the launcher argument parsing testable via a unit test (testng). > Also, a new test is provided covering the possible argument combinations. > > Thanks, > > -JB- -- Dmitry Samersoff Oracle Java development team, Saint Petersburg, Russia * I would love to change the world, but they won't give me the sources.
