maven-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From denn...@apache.org
Subject svn commit: r1449304 - /maven/plugins/trunk/maven-changelog-plugin/src/main/java/org/apache/maven/plugin/changelog/ChangeLogHandler.java
Date Sat, 23 Feb 2013 11:56:07 GMT
Author: dennisl
Date: Sat Feb 23 11:56:06 2013
New Revision: 1449304

URL: http://svn.apache.org/r1449304
Log:
[MCHANGELOG-108] read/write changelog.xml inconsistency
Submitted by: Samuel Van Reeth
Reviewed by: Dennis Lundberg

- Handle null

Modified:
    maven/plugins/trunk/maven-changelog-plugin/src/main/java/org/apache/maven/plugin/changelog/ChangeLogHandler.java

Modified: maven/plugins/trunk/maven-changelog-plugin/src/main/java/org/apache/maven/plugin/changelog/ChangeLogHandler.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-changelog-plugin/src/main/java/org/apache/maven/plugin/changelog/ChangeLogHandler.java?rev=1449304&r1=1449303&r2=1449304&view=diff
==============================================================================
--- maven/plugins/trunk/maven-changelog-plugin/src/main/java/org/apache/maven/plugin/changelog/ChangeLogHandler.java
(original)
+++ maven/plugins/trunk/maven-changelog-plugin/src/main/java/org/apache/maven/plugin/changelog/ChangeLogHandler.java
Sat Feb 23 11:56:06 2013
@@ -229,8 +229,16 @@ public class ChangeLogHandler
             }
 
             bufSet = new ChangeLogSet( bufEntries, startDate, endDate );
-            bufSet.setStartVersion( new ScmTag( attributes.getValue( "startVersion" ) ) );
-            bufSet.setEndVersion( new ScmTag( attributes.getValue( "endVersion" ) ) );
+            String startVersion = attributes.getValue( "startVersion" );
+            if ( startVersion != null )
+            {
+                bufSet.setStartVersion( new ScmTag( startVersion ) );
+            }
+            String endVersion = attributes.getValue( "endVersion" );
+            if ( endVersion != null )
+            {
+                bufSet.setEndVersion( new ScmTag( endVersion ) );
+            }
         }
     }
 }



Mime
View raw message