You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@ant.apache.org by bu...@apache.org on 2012/07/31 01:12:05 UTC

[Bug 53626] New: Applying expandproperties to an empty file raises NullPointerException

https://issues.apache.org/bugzilla/show_bug.cgi?id=53626

          Priority: P2
            Bug ID: 53626
          Assignee: notifications@ant.apache.org
           Summary: Applying expandproperties to an empty file raises
                    NullPointerException
          Severity: normal
    Classification: Unclassified
                OS: All
          Reporter: erickson_d@yahoo.com
          Hardware: All
            Status: NEW
           Version: 1.8.4
         Component: Core
           Product: Ant

Created attachment 29141
  --> https://issues.apache.org/bugzilla/attachment.cgi?id=29141&action=edit
A sample build file that serves as a test case for the bug.

When expandproperties is used in a filterchain that is applied to an empty
file, a NullPointerException is thrown from ExpandProperties:

BUILD FAILED
/home/erickson/foo/build.xml:7: java.lang.NullPointerException
    at
org.apache.tools.ant.filters.ExpandProperties.read(ExpandProperties.java:110)

The bug was introduced in
/ant/core/trunk/src/main/org/apache/tools/ant/filters/ExpandProperties.java
revision 1090431. The result of ParseProperties.parseProperties(String) may be
null. This result must be checked for null before invoking toString() on it.

This bug is not present in 1.8.2. It is present in 1.8.3 and 1.8.4.

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 53626] Applying expandproperties to an empty file raises NullPointerException

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=53626

Stefan Bodewig <bo...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|---                         |FIXED
   Target Milestone|---                         |1.9.0

--- Comment #1 from Stefan Bodewig <bo...@apache.org> ---
fixed with svn revision 1372266

Thanks!

-- 
You are receiving this mail because:
You are the assignee for the bug.