From ba073f34d4bcd979868c82957c83e9182a5b38fb Mon Sep 17 00:00:00 2001 From: Stefan Bodewig Date: Fri, 9 Sep 2005 21:00:28 +0000 Subject: [PATCH] use hashtable instead of getProperty which may return non-null even if the key is not in the hashtable. PR 36151 git-svn-id: https://svn.apache.org/repos/asf/ant/core/trunk@279876 13f79535-47bb-0310-9956-ffa450edef68 --- src/main/org/apache/tools/ant/types/PropertySet.java | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/main/org/apache/tools/ant/types/PropertySet.java b/src/main/org/apache/tools/ant/types/PropertySet.java index f8197824e..c1559654a 100644 --- a/src/main/org/apache/tools/ant/types/PropertySet.java +++ b/src/main/org/apache/tools/ant/types/PropertySet.java @@ -338,13 +338,11 @@ public class PropertySet extends DataType implements ResourceCollection { * avoid needless duplication of the Hashtable during recursion. */ private void addPropertyNames(Set names, Hashtable properties) { - Project prj = getProject(); - // Add this PropertySet's property names. for (Enumeration e = ptyRefs.elements(); e.hasMoreElements();) { PropertyRef r = (PropertyRef) e.nextElement(); if (r.name != null) { - if (prj != null && prj.getProperty(r.name) != null) { + if (properties.get(r.name) != null) { names.add(r.name); } } else if (r.prefix != null) {