REGRESSION: FUNCFLAG_FRESTRICTED check breaks VisualBasic Collection

Robert Shearman rob at codeweavers.com
Sun Jul 16 04:51:53 CDT 2006


a_villacis at palosanto.com wrote:

>As of 2006-07-14, the CVS snapshot of Wine 0.9.17 broke MS Visual Basic
>collections, when they ask for the _NewEnum in the _Collection interface.
>This method is used for the For Each...Next language construct, when
>applied
>to collection interfaces implemented in external DLLs (that is, collections
>compiled inside the same EXE where they are used are not affected). After a
>little digging I found that a recent patch adds a FUNCFLAG_FRESTRICTED check
>when looking for appropriate methods in an interface:
>
>(from dlls/oleaut32/typelib.c: 5223)
>
>    /* we do this instead of using GetFuncDesc since it will return a fake
>     * FUNCDESC for dispinterfaces and we want the real function
>description */
>    for (pFuncInfo = This->funclist; pFuncInfo; pFuncInfo=pFuncInfo->next)
>        if ((memid == pFuncInfo->funcdesc.memid) &&
>            (wFlags & pFuncInfo->funcdesc.invkind) &&
>            !(pFuncInfo->funcdesc.wFuncFlags & FUNCFLAG_FRESTRICTED))  
><-- breaks VB collections
>            break;
>
>If the FUNCFLAG_FRESTRICTED check is removed, the problem is solved. I would
>normally send in a patch for this, but since this check was deliberately
>added, there must be some other reason why this check was deemed necessary,
>so I am sending this notice instead.
>  
>

Yes, the change is obviously incorrect since it causes regressions. I 
think I should have been checking the restricted flag on the interface, 
rather than on the function.

-- 
Rob Shearman




More information about the wine-devel mailing list