[exsl] date:difference bug

[email protected] Mon, 3 Mar 2008 17:12:45 +0100 (CET)
Newsgroups gmane.text.xml.xslt.extensions
Message-ID <[email protected]>
hi!
i think that there is a bug in date.difference.template.xsl and
date.difference.function.xsl infact if you make the difference from
following date:
 2008-02-29T23:00:00
 2008-03-01T00:00:00

the result is -PT23H

i think taht a possible fix is to replace
....										<xsl:choose>
 <xsl:when test="$start-leap">
  <xsl:value-of select="$days + 1"/>
 </xsl:when>
 <xsl:otherwise>
  <xsl:value-of select="$days"/>
 </xsl:otherwise>
</xsl:choose>
...
whit:
....										<xsl:choose>
 <xsl:when test="$start-leap and $start-month &gt; 2">
  <xsl:value-of select="$days + 1"/>
 </xsl:when>
 <xsl:otherwise>
  <xsl:value-of select="$days"/>
 </xsl:otherwise>
</xsl:choose>
...


and
....										<xsl:choose>
 <xsl:when test="$end-leap">
  <xsl:value-of select="$days + 1"/>
 </xsl:when>
 <xsl:otherwise>
  <xsl:value-of select="$days"/>
 </xsl:otherwise>
</xsl:choose>
...
whit
....										<xsl:choose>
 <xsl:when test="$end-leap and $end-month &gt; 2">
  <xsl:value-of select="$days + 1"/>
 </xsl:when>
 <xsl:otherwise>
  <xsl:value-of select="$days"/>
 </xsl:otherwise>
</xsl:choose>
...