79597: [4/6] msxml3/sax: Support setting unlimited xml stream length for a reader

buildbot at kegel.com buildbot at kegel.com
Wed Oct 5 23:22:58 CDT 2011


This is an experimental automated build and test service.
Please feel free to ignore this email while we work the kinks out.

For more info about this message, see http://wiki.winehq.org/BuildBot

The Buildbot has detected a failed build on builder runtests-ati while building Wine.
Full details are available at: http://buildbot.kegel.com/builders/runtests-ati/builds/143 (though maybe not for long, as I'm still reinstalling the buildbot periodically while experimenting)
BUILD FAILED: failed git

Errors:
error: patch failed: dlls/msxml3/saxreader.c:206
error: dlls/msxml3/saxreader.c: patch does not apply
error: patch failed: dlls/msxml3/saxreader.c:64
error: dlls/msxml3/saxreader.c: patch does not apply
error: patch failed: dlls/msxml3/saxreader.c:217
error: dlls/msxml3/saxreader.c: patch does not apply
error: patch failed: dlls/msxml3/saxreader.c:2383
error: dlls/msxml3/saxreader.c: patch does not apply

-------------- next part --------------
From: Nikolay Sivov <nsivov at codeweavers.com>
Subject: [1/6] msxml3/sax: Accept disabled parameter entities feature
Message-Id: <4E8CA62C.3020706 at codeweavers.com>
Date: Wed, 05 Oct 2011 13:47:08 -0500

External entities are disabled anyway now

From fdc87452324ddbdb0437cf9a2d1b6b471c8c7f38 Mon Sep 17 00:00:00 2001
From: Nikolay Sivov <nsivov at codeweavers.com>
Date: Wed, 5 Oct 2011 09:20:32 -0500
Subject: [PATCH 4/9] Accept disabled parameter entities feature

---
 dlls/msxml3/saxreader.c |    8 ++++++++
 1 files changed, 8 insertions(+), 0 deletions(-)

diff --git a/dlls/msxml3/saxreader.c b/dlls/msxml3/saxreader.c
index 0460533..77373f1 100644
--- a/dlls/msxml3/saxreader.c
+++ b/dlls/msxml3/saxreader.c
@@ -206,6 +206,11 @@ static const WCHAR FeatureExternalGeneralEntitiesW[] = {
     '-','e','n','t','i','t','i','e','s',0
 };
 
+static const WCHAR FeatureExternalParameterEntitiesW[] = {
+    'h','t','t','p',':','/','/','x','m','l','.','o','r','g','/','s','a','x','/','f','e','a','t','u','r','e','s',
+    '/','e','x','t','e','r','n','a','l','-','p','a','r','a','m','e','t','e','r','-','e','n','t','i','t','i','e','s',0
+};
+
 static inline HRESULT set_feature_value(saxreader *reader, enum ReaderFeatures feature, VARIANT_BOOL value)
 {
     if (value == VARIANT_TRUE)
@@ -2614,6 +2619,9 @@ static HRESULT WINAPI saxxmlreader_putFeature(
     if (!strcmpW(FeatureExternalGeneralEntitiesW, feature) && value == VARIANT_FALSE)
         return set_feature_value(This, ExternalGeneralEntities, value);
 
+    if (!strcmpW(FeatureExternalParameterEntitiesW, feature) && value == VARIANT_FALSE)
+        return set_feature_value(This, ExternalParameterEntities, value);
+
     FIXME("(%p)->(%s %x) stub\n", This, debugstr_w(feature), value);
     return E_NOTIMPL;
 }
-- 
1.7.1

From: Nikolay Sivov <nsivov at codeweavers.com>
Subject: [2/6] msxml3/sax: Accept lexical handler param. entities switch
Message-Id: <4E8CA632.1070804 at codeweavers.com>
Date: Wed, 05 Oct 2011 13:47:14 -0500

Basically lexical handler is supposed to be called on CDATA and comments 
nodes only, and I don't see any libxml2 counterpart of such feature flag.

From d3f8a122662fb4de43f8ed0513765ea8cfb8593b Mon Sep 17 00:00:00 2001
From: Nikolay Sivov <nsivov at codeweavers.com>
Date: Wed, 5 Oct 2011 09:37:40 -0500
Subject: [PATCH 5/9] Accept lexical handler param. entities switch

---
 dlls/msxml3/saxreader.c |   14 +++++++++++++-
 1 files changed, 13 insertions(+), 1 deletions(-)

diff --git a/dlls/msxml3/saxreader.c b/dlls/msxml3/saxreader.c
index 77373f1..b7cd432 100644
--- a/dlls/msxml3/saxreader.c
+++ b/dlls/msxml3/saxreader.c
@@ -64,7 +64,8 @@ enum ReaderFeatures
     ServerHttpRequest            = 1 << 11,
     SuppressValidationfatalError = 1 << 12,
     UseInlineSchema              = 1 << 13,
-    UseSchemaLocation            = 1 << 14
+    UseSchemaLocation            = 1 << 14,
+    LexicalHandlerParEntities    = 1 << 15
 };
 
 struct bstrpool
@@ -211,6 +212,11 @@ static const WCHAR FeatureExternalParameterEntitiesW[] = {
     '/','e','x','t','e','r','n','a','l','-','p','a','r','a','m','e','t','e','r','-','e','n','t','i','t','i','e','s',0
 };
 
+static const WCHAR FeatureLexicalHandlerParEntitiesW[] = {
+    'h','t','t','p',':','/','/','x','m','l','.','o','r','g','/','s','a','x','/','f','e','a','t','u','r','e','s',
+    '/','l','e','x','i','c','a','l','-','h','a','n','d','l','e','r','/','p','a','r','a','m','e','t','e','r','-','e','n','t','i','t','i','e','s',0
+};
+
 static inline HRESULT set_feature_value(saxreader *reader, enum ReaderFeatures feature, VARIANT_BOOL value)
 {
     if (value == VARIANT_TRUE)
@@ -2622,6 +2628,12 @@ static HRESULT WINAPI saxxmlreader_putFeature(
     if (!strcmpW(FeatureExternalParameterEntitiesW, feature) && value == VARIANT_FALSE)
         return set_feature_value(This, ExternalParameterEntities, value);
 
+    if (!strcmpW(FeatureLexicalHandlerParEntitiesW, feature))
+    {
+        FIXME("(%p)->(%s %x) stub\n", This, debugstr_w(feature), value);
+        return set_feature_value(This, LexicalHandlerParEntities, value);
+    }
+
     FIXME("(%p)->(%s %x) stub\n", This, debugstr_w(feature), value);
     return E_NOTIMPL;
 }
-- 
1.7.1

From: Nikolay Sivov <nsivov at codeweavers.com>
Subject: [3/6] msxml3/sax: Accept DTD prohibition feature
Message-Id: <4E8CA638.20208 at codeweavers.com>
Date: Wed, 05 Oct 2011 13:47:20 -0500

libxml2 always parses DTD if it's present, so I don't see how we should 
skip it, also we don't use any dtd handlers currently, so this should be 
harmless.

From 5572dcf4886f7f3b673519c555861de562dfc8ee Mon Sep 17 00:00:00 2001
From: Nikolay Sivov <nsivov at codeweavers.com>
Date: Wed, 5 Oct 2011 11:09:28 -0500
Subject: [PATCH 6/9] Accept DTD prohibition feature

---
 dlls/msxml3/saxreader.c |   10 ++++++++++
 1 files changed, 10 insertions(+), 0 deletions(-)

diff --git a/dlls/msxml3/saxreader.c b/dlls/msxml3/saxreader.c
index b7cd432..8498b8d 100644
--- a/dlls/msxml3/saxreader.c
+++ b/dlls/msxml3/saxreader.c
@@ -217,6 +217,10 @@ static const WCHAR FeatureLexicalHandlerParEntitiesW[] = {
     '/','l','e','x','i','c','a','l','-','h','a','n','d','l','e','r','/','p','a','r','a','m','e','t','e','r','-','e','n','t','i','t','i','e','s',0
 };
 
+static const WCHAR FeatureProhibitDTDW[] = {
+    'p','r','o','h','i','b','i','t','-','d','t','d',0
+};
+
 static inline HRESULT set_feature_value(saxreader *reader, enum ReaderFeatures feature, VARIANT_BOOL value)
 {
     if (value == VARIANT_TRUE)
@@ -2634,6 +2638,12 @@ static HRESULT WINAPI saxxmlreader_putFeature(
         return set_feature_value(This, LexicalHandlerParEntities, value);
     }
 
+    if (!strcmpW(FeatureProhibitDTDW, feature))
+    {
+        FIXME("(%p)->(%s %x) stub\n", This, debugstr_w(feature), value);
+        return set_feature_value(This, ProhibitDTD, value);
+    }
+
     FIXME("(%p)->(%s %x) stub\n", This, debugstr_w(feature), value);
     return E_NOTIMPL;
 }
-- 
1.7.1

From: Nikolay Sivov <nsivov at codeweavers.com>
Subject: [4/6] msxml3/sax: Support setting unlimited xml stream length for a reader
Message-Id: <4E8CA63F.7010808 at codeweavers.com>
Date: Wed, 05 Oct 2011 13:47:27 -0500

libxml2 doesn't limit stream length itself, so this change has no impact 
on parser.

From e647bf87ce87742ee65d25562a54f5b84c9a4a78 Mon Sep 17 00:00:00 2001
From: Nikolay Sivov <nsivov at codeweavers.com>
Date: Wed, 5 Oct 2011 11:19:43 -0500
Subject: [PATCH 7/9] Support setting unlimited xml stream length for a reader

---
 dlls/msxml3/saxreader.c |   12 ++++++++----
 1 files changed, 8 insertions(+), 4 deletions(-)

diff --git a/dlls/msxml3/saxreader.c b/dlls/msxml3/saxreader.c
index 8498b8d..857083a 100644
--- a/dlls/msxml3/saxreader.c
+++ b/dlls/msxml3/saxreader.c
@@ -2383,7 +2383,14 @@ static HRESULT internal_putProperty(
         return S_OK;
     }
 
-    FIXME("(%p)->(%s): unsupported property\n", This, debugstr_w(prop));
+    if(!memcmp(prop, PropertyMaxXMLSizeW, sizeof(PropertyMaxXMLSizeW)))
+    {
+        if (V_VT(&value) == VT_I4 && V_I4(&value) == 0) return S_OK;
+        FIXME("(%p)->(%s): max-xml-size unsupported\n", This, debugstr_variant(&value));
+        return E_NOTIMPL;
+    }
+
+    FIXME("(%p)->(%s:%s): unsupported property\n", This, debugstr_w(prop), debugstr_variant(&value));
 
     if(!memcmp(prop, PropertyCharsetW, sizeof(PropertyCharsetW)))
         return E_NOTIMPL;
@@ -2397,9 +2404,6 @@ static HRESULT internal_putProperty(
     if(!memcmp(prop, PropertyMaxElementDepthW, sizeof(PropertyMaxElementDepthW)))
         return E_NOTIMPL;
 
-    if(!memcmp(prop, PropertyMaxXMLSizeW, sizeof(PropertyMaxXMLSizeW)))
-        return E_NOTIMPL;
-
     if(!memcmp(prop, PropertySchemaDeclHandlerW, sizeof(PropertySchemaDeclHandlerW)))
         return E_NOTIMPL;
 
-- 
1.7.1



More information about the wine-tests-results mailing list