File tree Expand file tree Collapse file tree 1 file changed +6
-6
lines changed
opengrok-indexer/src/main/java/org/opengrok/indexer/index Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change 2626
2727import java .io .File ;
2828import java .io .IOException ;
29+ import java .io .PrintStream ;
2930import java .lang .reflect .Field ;
3031import java .lang .reflect .InvocationTargetException ;
3132import java .net .URI ;
@@ -145,12 +146,11 @@ public static void main(String[] argv) {
145146 try {
146147 argv = parseOptions (argv );
147148 if (help ) {
148- status = 1 ;
149- System . err .println (helpUsage );
149+ PrintStream helpStream = status != 0 ? System . err : System . out ;
150+ helpStream .println (helpUsage );
150151 if (helpDetailed ) {
151- System .err .println (AnalyzerGuruHelp .getUsage ());
152- System .err .println (
153- ConfigurationHelp .getSamples ());
152+ helpStream .println (AnalyzerGuruHelp .getUsage ());
153+ helpStream .println (ConfigurationHelp .getSamples ());
154154 }
155155 System .exit (status );
156156 }
@@ -414,7 +414,7 @@ public static String[] parseOptions(String[] argv) throws ParseException {
414414
415415 if (argv .length == 0 ) {
416416 argv = usage ; // will force usage output
417- status = 1 ;
417+ status = 1 ; // with non-zero EXIT STATUS
418418 }
419419
420420 /*
You can’t perform that action at this time.
0 commit comments