gnodet commented on code in PR #2117:
URL: https://github.com/apache/maven/pull/2117#discussion_r1967511670


##########
impl/maven-cli/src/main/java/org/apache/maven/cling/invoker/mvnenc/EncryptInvoker.java:
##########
@@ -78,8 +78,8 @@ protected int execute(EncryptContext context) throws 
Exception {
             context.addInHeader("This tool is part of Apache Maven 4 
distribution.");
             context.addInHeader("");
 
-            Thread executeThread = Thread.currentThread();
-            context.terminal.handle(Terminal.Signal.INT, signal -> 
executeThread.interrupt());
+            context.terminal.handle(
+                    Terminal.Signal.INT, signal -> 
Thread.currentThread().interrupt());

Review Comment:
   That sounds weird.  The current thread cannot be the Maven execution thread, 
unless maybe it actually reads from stdin.  It should be a terminal's pump 
thread.



-- 
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: issues-unsubscr...@maven.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to