diff --git a/maven-core/src/main/java/org/apache/maven/DefaultMaven.java b/maven-core/src/main/java/org/apache/maven/DefaultMaven.java index 7bed0639a1..b1f239acec 100644 --- a/maven-core/src/main/java/org/apache/maven/DefaultMaven.java +++ b/maven-core/src/main/java/org/apache/maven/DefaultMaven.java @@ -264,6 +264,8 @@ public class DefaultMaven return processResult( result, e ); } + repoSession.setReadOnly(); + ClassLoader originalClassLoader = Thread.currentThread().getContextClassLoader(); try {