Huw Davies : msxml3/tests: Don' t test the values of alignment holes in the variant structure.

Alexandre Julliard julliard at winehq.org
Tue May 13 14:23:46 CDT 2014


Module: wine
Branch: master
Commit: 25e5daf87232c041bdb991fea5f4c17f9ca7bb04
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=25e5daf87232c041bdb991fea5f4c17f9ca7bb04

Author: Huw Davies <huw at codeweavers.com>
Date:   Tue May 13 09:20:49 2014 +0100

msxml3/tests: Don't test the values of alignment holes in the variant structure.

---

 dlls/msxml3/tests/schema.c |   10 +++-------
 1 file changed, 3 insertions(+), 7 deletions(-)

diff --git a/dlls/msxml3/tests/schema.c b/dlls/msxml3/tests/schema.c
index 658b0d7..1145bd5 100644
--- a/dlls/msxml3/tests/schema.c
+++ b/dlls/msxml3/tests/schema.c
@@ -1275,24 +1275,20 @@ static void test_XDR_datatypes(void)
     while (ptr->query)
     {
         IXMLDOMNode* node = NULL;
-        VARIANT type, testv;
+        VARIANT type;
 
         /* check data types without the schema */
-        memset(&testv, -1, sizeof(VARIANT));
-        V_VT(&testv) = VT_NULL;
-        V_BSTR(&testv) = NULL;
-
         hr = IXMLDOMDocument2_selectSingleNode(doc, _bstr_(ptr->query), &node);
         EXPECT_HR(hr, S_OK);
         ok(node != NULL, "expected node\n");
 
-        memset(&type, -1, sizeof(VARIANT));
         V_VT(&type) = VT_EMPTY;
+        V_BSTR(&type) = (void*)-1;
         hr = IXMLDOMNode_get_dataType(node, &type);
         EXPECT_HR(hr, S_FALSE);
         ok(V_VT(&type) == VT_NULL, "got type %i\n", V_VT(&type));
         /* when returning VT_NULL, the pointer is set to NULL */
-        ok(!memcmp(&testv, &type, sizeof(VARIANT)), "got %p\n", V_BSTR(&type));
+        ok(V_BSTR(&type) == NULL, "got %p\n", V_BSTR(&type));
 
         VariantClear(&type);
         hr = IXMLDOMNode_get_nodeTypedValue(node, &type);




More information about the wine-cvs mailing list