oleaut32: fix regression at MSFT typelib parsing

Detlef Riekenberg wine.dev at web.de
Fri Nov 3 14:19:46 CST 2006


On Fr, 2006-11-03 at 11:42 -0500, a_villacis at palosanto.com wrote:
> Finally, I managed to figure out the proper fix for the crash on
> regsvr32 msvbvm60.dll 

Great!
Thanks for your investigation.

I have no Idea about ole, but...

>    MESSAGE("\thelpstring: %s\n", debugstr_w(pfd->HelpString));
> -  MESSAGE("\tentry: %s\n", debugstr_w(pfd->Entry));
> +  if (HIWORD(pfd->Entry) == 0)
> +      MESSAGE("\tentry (ordinal): 0x%04x\n", (INT)pfd->Entry);
> +  else if (pfd->Entry != (void *)-1)
> +      MESSAGE("\tentry (string): %s\n", debugstr_w(pfd->Entry));
> +  else
> +      MESSAGE("\tentry (invalid): -1\n");

Pointers with "HIWORD() == 0" are already handled by debugstr_w().
You will get a "#" followed by the number.

I suggest to reuse the old code:
MESSAGE("\tentry: %s\n", (entry == -1) ? "-1 (invalid)" :
debugstr_w(pfd->Entry));

Another Idea is to check only for "-1" and use 
the previous code unmodified for all other cases.


-- 
 
By by ... Detlef





More information about the wine-devel mailing list