DBGRID32.OCX fix - RFC
Robert Shearman
rob at codeweavers.com
Fri Dec 2 11:42:30 CST 2005
Alex Villacís Lasso wrote:
> I would like to know if the attached patch (which prevents
> DBGRID32.OCX from crashing, as well as adding additional debugging
> information when a reference is not found) would step on anybody's
> toes (especially Robert Shearman, since he is sending several oleaut32
> patches himself). As of 2005-12-01 CVS, any VisualBasic application
> that tries to use DBGRID32.OCX will systematically crash unless the
> patch is applied. However, since Robert Shearman is sending oleaut32
> fixes, I think he might implement some functionality that will, as a
> side effect, fix the DBGRID32.OCX bug.
No, I have no plans to change anything that should affect this.
> ITypeInfoImpl *This = (ITypeInfoImpl *)iface;
> HRESULT result = E_FAIL;
>
>- if (hRefType == -1 &&
>- (((ITypeInfoImpl*) This)->TypeAttr.typekind == TKIND_DISPATCH) &&
>- (((ITypeInfoImpl*) This)->TypeAttr.wTypeFlags & TYPEFLAG_FDUAL))
>+ if (
>+ (
>+ hRefType == -1 &&
>+ (This->TypeAttr.typekind == TKIND_DISPATCH) &&
>+ (This->TypeAttr.wTypeFlags & TYPEFLAG_FDUAL)
>+ )
>+ ||
>+ (
>+ (This->TypeAttr.typekind == TKIND_DISPATCH) &&
>+ (This->TypeAttr.wTypeFlags & TYPEFLAG_FDISPATCHABLE)
>+ )
>+ )
> {
>
>
What hRefType is passed to the function? I don't think the above is
quite correct. Can you try changing the if statement to something like this:
if (hRefType == -1 &&
(This->TypeAttr.typekind == TKIND_DISPATCH) &&
(This->TypeAttr.wTypeFlags & (TYPEFLAG_FDUAL|TYPEFLAG_FDISPATCHABLE)))
--
Rob Shearman
More information about the wine-devel
mailing list