From 7f4dc2f9c07df3c0740d87cd6f10902a2d21046b Mon Sep 17 00:00:00 2001 From: Brett Leslie Porter Date: Tue, 1 Mar 2005 04:03:24 +0000 Subject: [PATCH] error handling git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@163437 13f79535-47bb-0310-9956-ffa450edef68 --- .../java/org/apache/maven/plugin/DefaultPluginManager.java | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/maven-core/src/main/java/org/apache/maven/plugin/DefaultPluginManager.java b/maven-core/src/main/java/org/apache/maven/plugin/DefaultPluginManager.java index 1a39c15939..c572e764a0 100644 --- a/maven-core/src/main/java/org/apache/maven/plugin/DefaultPluginManager.java +++ b/maven-core/src/main/java/org/apache/maven/plugin/DefaultPluginManager.java @@ -265,6 +265,10 @@ public class DefaultPluginManager PluginExecutionResponse response; MojoDescriptor mojoDescriptor = getMojoDescriptor( goalName ); + if ( mojoDescriptor == null ) + { + throw new GoalExecutionException( "Unable to find goal: " + goalName ); + } if ( mojoDescriptor.requiresDependencyResolution() ) {