fixed a stupid cut'npaste bug #139132 added test to the regression for bug
authorDaniel Veillard <veillard@src.gnome.org>
Mon, 5 Apr 2004 13:26:19 +0000 (13:26 +0000)
committerDaniel Veillard <veillard@src.gnome.org>
Mon, 5 Apr 2004 13:26:19 +0000 (13:26 +0000)
* libxslt/keys.c: fixed a stupid cut'npaste bug #139132
* tests/docs/Makefile.am tests/docs/bug-146.xml
  tests/general/Makefile.am tests/docs/bug-146*: added test
  to the regression for bug #139132
Daniel

ChangeLog
NEWS
tests/docs/Makefile.am
tests/docs/bug-146.xml [new file with mode: 0644]
tests/general/Makefile.am
tests/general/bug-146.out [new file with mode: 0644]
tests/general/bug-146.xsl [new file with mode: 0644]

index 8a9f749..377bc4c 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+Mon Apr  5 15:23:53 CEST 2004 Daniel Veillard <daniel@veillard.com>
+
+       * libxslt/keys.c: fixed a stupid cut'npaste bug #139132
+       * tests/docs/Makefile.am tests/docs/bug-146.xml
+         tests/general/Makefile.am tests/docs/bug-146*: added test
+         to the regression for bug #139132
+
 2004-04-02 10:17:23 HKT 2004 William Brack <wbrack@mmm.com.hk>
 
        * libxslt/keys.c: applied patch from Mark Vakoc to fix problem
diff --git a/NEWS b/NEWS
index 35424a1..71a1b2a 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -4,12 +4,7 @@
   Note that this is automatically generated from the news webpage at:
        http://xmlsoft.org/XSLT/news.html
 
-
-CVS only : check the Changelog at 
-http://cvs.gnome.org/lxr/source/libxslt/ChangeLog
- file
-for a really accurate description:
-
+Those are the public releases made:
 1.1.5: Mar 23 2004:
    - performance: use dictionnary lookup for variables
    - remove use of _private from source documents
index 6572ce1..85f94ba 100644 (file)
@@ -145,6 +145,7 @@ EXTRA_DIST =        \
        bug-143.xml \
        bug-144.xml \
        bug-145.xml \
+       bug-146.xml \
        character.xml \
        array.xml \
        items.xml
diff --git a/tests/docs/bug-146.xml b/tests/docs/bug-146.xml
new file mode 100644 (file)
index 0000000..f879acd
--- /dev/null
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="windows-1251"?>
+<!-- edited with XMLSPY v2004 rel. 2 U (http://www.xmlspy.com) by Victor 
+Prylipko (Linia) -->
+<root>
+    <colls COL_COD="PT" COL_NAME="Àðãî" CURR_ID_0="" CURR_ID_1="" CURR_ID_2="" 
+CURR_ID_3="">
+        <goodcoll CODE="2655" ART="PA310ST" NAME="Êîìïëåêò ñòåêîë äëÿ À310 òîí" 
+WEIGHT="10" VOLUME="0.09" GABS_W="72" GABS_H="112" GABS_D="0.4" SH_DESC="" 
+SUPP_ART="PA310ST" NUM="0" COL_COD="PT" 
+IMAGE_="/images/goods/image/PA310ST.gif" 
+SCHEMA_="/images/goods/schema/PA310ST.gif">
+            <currency CURRENCY_="RUR" OPT="1" ROZN="2" ZAKUP="3" IN="4"/>
+            <currency CURRENCY_="USD" OPT="2" ROZN="3" ZAKUP="4" IN="5"/>
+            <goodcomb GOOD_ID="63647" NUM_COLOR="0" COL_ID="24007" 
+TITLE="ïóñòîé" COEF="0" ABS_COEF="0" RU_CODE="" EN_CODE="" PROPNAME_="C" 
+MODEL_="">
+                <ost NUM_TIP="0" TIP="0"/>
+                <ost NUM_TIP="2" TIP="-3"/>
+                <ost NUM_TIP="4" TIP="-4"/>
+                <ost NUM_TIP="5" TIP="-4"/>
+                <ost NUM_TIP="6" TIP="-4"/>
+                <ost NUM_TIP="7" TIP="-3"/>
+                <ost NUM_TIP="8" TIP="-3"/>
+                <ost NUM_TIP="9" TIP="-3"/>
+            </goodcomb>
+        </goodcoll>
+    </colls>
+</root>
index 2d08bee..4bd304c 100644 (file)
@@ -151,6 +151,7 @@ EXTRA_DIST = \
     bug-143.out bug-143.xsl \
     bug-144.out bug-144.xsl \
     bug-145.out bug-145.xsl bug-145.err \
+    bug-146.out bug-146.xsl \
     character.out character.xsl \
     character2.out character2.xsl \
     itemschoose.out itemschoose.xsl \
diff --git a/tests/general/bug-146.out b/tests/general/bug-146.out
new file mode 100644 (file)
index 0000000..d88e13a
--- /dev/null
@@ -0,0 +1,6 @@
+<?xml version="1.0" encoding="windows-1251"?>
+<root>
+  <colls COL_COD="PT" COL_NAME="Àðãî" CURR_ID_0="" CURR_ID_1="" CURR_ID_2="" CURR_ID_3="">
+    <color COL_ID="24007" TITLE="ïóñòîé" RU_CODE=""/>
+  </colls>
+</root>
diff --git a/tests/general/bug-146.xsl b/tests/general/bug-146.xsl
new file mode 100644 (file)
index 0000000..c8f8149
--- /dev/null
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="windows-1251"?>
+<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
+<xsl:output method="xml" encoding="windows-1251" indent="yes"/>
+<xsl:strip-space elements="*"/>
+<xsl:key name="EMPTY_EN_CODE_COLLS" match="/root/colls/goodcoll/goodcomb/@COL_ID
+[../@EN_CODE = '']" use="../../../@COL_COD"/>
+<xsl:key name="EMPTY_EN_CODE_COLRS" match="/root/colls/goodcoll/goodcomb/@COL_ID
+[../@EN_CODE = '']" use="concat(.,':',../../../@COL_COD)"/>
+<xsl:template match="/">
+<root>
+ <xsl:for-each select="/root/colls[key('EMPTY_EN_CODE_COLLS',@COL_COD)]">
+  <xsl:copy>
+   <xsl:copy-of select="@*"/>
+   <xsl:for-each select="key('EMPTY_EN_CODE_COLLS',@COL_COD)[generate-id(.) = 
+generate-id(key('EMPTY_EN_CODE_COLRS',concat(.,':',../../../@COL_COD)))]">
+    <color>
+     <xsl:copy-of select="../@TITLE | ../@RU_CODE | ."/>
+    </color>
+   </xsl:for-each>
+  </xsl:copy>
+ </xsl:for-each>
+</root>
+</xsl:template>
+</xsl:stylesheet>