You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@ant.apache.org by bo...@apache.org on 2022/01/12 18:01:21 UTC

[ant] branch master updated: make PropertyHelper a bit more backwards compatible

This is an automated email from the ASF dual-hosted git repository.

bodewig pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/ant.git


The following commit(s) were added to refs/heads/master by this push:
     new 2972b55  make PropertyHelper a bit more backwards compatible
2972b55 is described below

commit 2972b55fb5459ea7d0bc23d102564dc6205551f9
Author: Stefan Bodewig <bo...@apache.org>
AuthorDate: Wed Jan 12 19:00:29 2022 +0100

    make PropertyHelper a bit more backwards compatible
    
    Bugzilla Report 65799
---
 WHATSNEW                                          | 8 ++++++++
 src/main/org/apache/tools/ant/PropertyHelper.java | 2 +-
 2 files changed, 9 insertions(+), 1 deletion(-)

diff --git a/WHATSNEW b/WHATSNEW
index ff6e43a..7d5f2c4 100644
--- a/WHATSNEW
+++ b/WHATSNEW
@@ -10,6 +10,14 @@ Changes that could break older environments:
   credentials being used on the redirected URI may break.
   Github Pull Request #173
 
+Fixed bugs:
+-----------
+
+* the ProperyEnumerator change introduced in 1.10.9 proved to be not
+  fully backwards compatible when combined with certain custom
+  PropertyHelper implementations - for example when using AntXtras.
+  Bugzilla Report 65799
+
 Other changes:
 --------------
 
diff --git a/src/main/org/apache/tools/ant/PropertyHelper.java b/src/main/org/apache/tools/ant/PropertyHelper.java
index 53ec6ee..99d1a29 100644
--- a/src/main/org/apache/tools/ant/PropertyHelper.java
+++ b/src/main/org/apache/tools/ant/PropertyHelper.java
@@ -860,7 +860,7 @@ public class PropertyHelper implements GetProperty {
      * @return the names of all known properties.
      */
     public Set<String> getPropertyNames() {
-        final Set<String> names = new HashSet<>(properties.keySet());
+        final Set<String> names = new HashSet<>(getProperties().keySet());
         getDelegates(PropertyEnumerator.class)
             .forEach(e -> names.addAll(e.getPropertyNames()));
         return Collections.unmodifiableSet(names);