Browse Source

avoid NPE in border-cases

git-svn-id: https://svn.apache.org/repos/asf/ant/core/trunk@426648 13f79535-47bb-0310-9956-ffa450edef68
master
Stefan Bodewig 19 years ago
parent
commit
8a7b803fb1
1 changed files with 4 additions and 0 deletions
  1. +4
    -0
      src/main/org/apache/tools/ant/types/PropertySet.java

+ 4
- 0
src/main/org/apache/tools/ant/types/PropertySet.java View File

@@ -320,6 +320,9 @@ public class PropertySet extends DataType implements ResourceCollection {
for (Iterator iter = names.iterator(); iter.hasNext();) {
String name = (String) iter.next();
String value = (String) props.get(name);
if (value != null) {
// may be null if a system property has been added
// after the project instance has been initialized
if (m != null) {
//map the names
String[] newname = m.mapFileName(name);
@@ -328,6 +331,7 @@ public class PropertySet extends DataType implements ResourceCollection {
}
}
properties.setProperty(name, value);
}
}
return properties;
}


Loading…
Cancel
Save