oleaut32: Conformance test and patch for VarCat
qingdoa daoo
qingdao33122 at yahoo.com
Fri Jul 14 19:39:44 CDT 2006
--- qingdoa daoo <qingdao33122 at yahoo.com> wrote:
> --- Benjamin Arai <me at benjaminarai.com> wrote:
>
> > See http://bugs.winehq.com/show_bug.cgi?id=5545
> > License: LGPL
> >
> > Changelog:
> > - oleaut32: Add conformance test for VarCat
> > - oleaut32: Update VarCat function to address all conformance test
> > failures
> > - Tests all pass on Windows XP SP2 and Wine
> >
> > > >From 61bbc58d652c97b70309c0fd37107e60cbaad86a Mon Sep 17 00:00:00 2001
> > From: Benjamin Arai <barai at barai.smo.corp.google.com>
> > Date: Mon, 10 Jul 2006 09:12:46 -0700
> > Subject: [PATCH] oleaut32:VarCat - Adds conformance test and updates VarCat to pass
> all
> > tests
> > ---
> > dlls/oleaut32/tests/vartest.c | 319 +++++++++++++++++++++++++++++++++++++++++
> > dlls/oleaut32/variant.c | 150 +++++++++++++++----
> > 2 files changed, 439 insertions(+), 30 deletions(-)
> >
> > diff --git a/dlls/oleaut32/tests/vartest.c b/dlls/oleaut32/tests/vartest.c
> > index e8e4654..ba7ba84 100644
> > --- a/dlls/oleaut32/tests/vartest.c
> > +++ b/dlls/oleaut32/tests/vartest.c
> === message truncated ===>
> >
>
> Be careful when you call VariantClear. Calling VariantClear on a random value is
> dangerous.
>
> Specifically,
> Before a local variable is initialzed its content is undefined.
> When a function call fails the content of the output buffer is usually undefined.
>
Another problem.
Your test for VarCat won't catch many cases in which native returns S_OK while our code
fails.
hres = VarCat(&left, &right, &result);
......
if (hres != S_OK)
{
HRESULT expected_error_num;
......
The test may pass on Windows because the hres is S_OK and on Wine because hres is the
expected error num according to our test code.
___________________________________________________________
ÇÀ×¢ÑÅ»¢Ãâ·ÑÓÊÏä-3.5GÈÝÁ¿£¬20M¸½¼þ£¡
http://cn.mail.yahoo.com
More information about the wine-devel
mailing list