You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by kh...@apache.org on 2015/07/06 20:22:13 UTC
maven git commit: [MNG-5816] Empy maven.config cause Maven to exit
with failure
Repository: maven
Updated Branches:
refs/heads/master f104ef885 -> 193778ec0
[MNG-5816] Empy maven.config cause Maven to exit with failure
Avoid adding non empty configuration argument that causes exception.
Signed-off-by: Karl Heinz Marbaise <kh...@apache.org>
Project: http://git-wip-us.apache.org/repos/asf/maven/repo
Commit: http://git-wip-us.apache.org/repos/asf/maven/commit/193778ec
Tree: http://git-wip-us.apache.org/repos/asf/maven/tree/193778ec
Diff: http://git-wip-us.apache.org/repos/asf/maven/diff/193778ec
Branch: refs/heads/master
Commit: 193778ec0e780ebf89138f5104ead881c0e3899f
Parents: f104ef8
Author: tssp <ts...@web.de>
Authored: Wed Apr 29 10:22:38 2015 +0200
Committer: Karl Heinz Marbaise <kh...@apache.org>
Committed: Mon Jul 6 20:21:39 2015 +0200
----------------------------------------------------------------------
maven-embedder/src/main/java/org/apache/maven/cli/MavenCli.java | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/maven/blob/193778ec/maven-embedder/src/main/java/org/apache/maven/cli/MavenCli.java
----------------------------------------------------------------------
diff --git a/maven-embedder/src/main/java/org/apache/maven/cli/MavenCli.java b/maven-embedder/src/main/java/org/apache/maven/cli/MavenCli.java
index 8ce299f..034cb00 100644
--- a/maven-embedder/src/main/java/org/apache/maven/cli/MavenCli.java
+++ b/maven-embedder/src/main/java/org/apache/maven/cli/MavenCli.java
@@ -377,7 +377,10 @@ public class MavenCli
{
for ( String arg : Files.toString( configFile, Charsets.UTF_8 ).split( "\\s+" ) )
{
- args.add( arg );
+ if ( !arg.isEmpty() )
+ {
+ args.add( arg );
+ }
}
CommandLine config = cliManager.parse( args.toArray( new String[args.size()] ) );