From ba57376e69e28a67f2300f4d086d3b124735ffe8 Mon Sep 17 00:00:00 2001 From: Benjamin Bentmann Date: Sat, 23 May 2009 16:37:46 +0000 Subject: [PATCH] o Prevented NPEs in downstream code git-svn-id: https://svn.apache.org/repos/asf/maven/components/branches/MNG-2766@777957 13f79535-47bb-0310-9956-ffa450edef68 --- .../DefaultProjectBuilderConfiguration.java | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/maven-core/src/main/java/org/apache/maven/project/DefaultProjectBuilderConfiguration.java b/maven-core/src/main/java/org/apache/maven/project/DefaultProjectBuilderConfiguration.java index baa40433d2..0f77e1d23f 100644 --- a/maven-core/src/main/java/org/apache/maven/project/DefaultProjectBuilderConfiguration.java +++ b/maven-core/src/main/java/org/apache/maven/project/DefaultProjectBuilderConfiguration.java @@ -82,6 +82,10 @@ public class DefaultProjectBuilderConfiguration public Properties getExecutionProperties() { + if ( executionProperties == null ) + { + executionProperties = new Properties(); + } return executionProperties; } @@ -115,6 +119,10 @@ public class DefaultProjectBuilderConfiguration public List getActiveProfileIds() { + if ( activeProfileIds == null ) + { + activeProfileIds = new ArrayList(); + } return activeProfileIds; } @@ -125,6 +133,10 @@ public class DefaultProjectBuilderConfiguration public List getInactiveProfileIds() { + if ( inactiveProfileIds == null ) + { + inactiveProfileIds = new ArrayList(); + } return inactiveProfileIds; } @@ -150,6 +162,11 @@ public class DefaultProjectBuilderConfiguration public List getProfiles() { + if ( profiles == null ) + { + profiles = new ArrayList(); + } return profiles; } + }