[PATCH 2/2] oledb32: GetConversionSize shouldn't fail for null variants.

Huw Davies huw at codeweavers.com
Tue Dec 22 03:03:02 CST 2015


On Tue, Dec 22, 2015 at 06:32:04PM +1100, Alistair Leslie-Hughes wrote:
> diff --git a/dlls/oledb32/tests/convert.c b/dlls/oledb32/tests/convert.c
> index a785457..55539f9 100644
> --- a/dlls/oledb32/tests/convert.c
> +++ b/dlls/oledb32/tests/convert.c
> @@ -2627,6 +2627,33 @@ static void test_getconversionsize(void)
>      ok(hr == S_OK, "got 0x%08x\n", hr);
>      VariantClear(&var);
>  
> +    dst_len = 78;
> +    V_VT(&var) = VT_NULL;
> +    hr = IDataConvert_GetConversionSize(convert, DBTYPE_VARIANT, DBTYPE_WSTR, NULL, &dst_len, &var);
> +    ok(hr == S_OK, "got 0x%08x\n", hr);

You should test dst_len after return.  Likewise below.

Huw.



More information about the wine-devel mailing list