cxzl25 commented on code in PR #1817:
URL: https://github.com/apache/orc/pull/1817#discussion_r1503572991


##########
java/tools/src/java/org/apache/orc/tools/RowCount.java:
##########
@@ -66,7 +66,9 @@ public static void main(Configuration conf, String[] args) 
throws Exception {
         }
       }
     }
-    System.exit(bad == 0 ? 0 : 1);
+    if (bad > 0) {
+      System.exit(1);
+    }

Review Comment:
   Before Java17, we could use `SecurityManager` to intercept `System.exit` for 
testing, but we are in Java17 now, so I will propose another PR to avoid 
`System.exit(0)`.
   
   https://www.dontpanicblog.co.uk/2022/10/30/testing-system-exit/
   
   https://openjdk.org/jeps/411



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to