[5/5] oledb32: GetConversionSize only returns a valid size of BSTR

Nikolay Sivov bunglehead at gmail.com
Thu May 23 12:52:48 CDT 2013


On Thu, May 23, 2013 at 11:48 AM, Alistair Leslie-Hughes <
leslie_alistair at hotmail.com> wrote:

> Hi,
>
>
> Changelog:
>     oledb32: GetConversionSize only returns a valid size of BSTR
>



+            if(V_VT((VARIANT*)src) != VT_BSTR)
+                *dst_len = 110;
             else
-                return hr;
+                *dst_len = (SysStringLen(V_BSTR((VARIANT*)src)) + 1)
* sizeof(WCHAR);
+
+            return S_OK;

So it returns previous result if type is invalid, meaning it's not
VT_BSTR? You can't just return a random
constant that appears in tests just because of previously made call
(which is my guess). If you really
want to implement this broken behaviour it will need more tests, at
least one more that shows it returns
a result from last successful call.






>
> Best Regards
>  Alistair Leslie-Hughes
>
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.winehq.org/pipermail/wine-devel/attachments/20130523/c6ed0586/attachment.html>


More information about the wine-devel mailing list