Re: [1/3] shlwapi/tests: Move the function pointers to the string test functions where they are initialized and used.
Francois Gouget <fgouget(a)free.fr> writes:
It makes no sense to declare the function pointers globally, but then only initialiaze them in one function or another. This is a recipe for adding code that calls the function pointer elsewhere... and before it has been initialized of course.
Actually the reason for declaring them globally is that 2.x gcc versions sometimes crash on local WINAPI function pointers. -- Alexandre Julliard julliard(a)winehq.org
On Mon, 3 Mar 2008, Alexandre Julliard wrote:
Francois Gouget <fgouget(a)free.fr> writes:
It makes no sense to declare the function pointers globally, but then only initialiaze them in one function or another. This is a recipe for adding code that calls the function pointer elsewhere... and before it has been initialized of course.
Actually the reason for declaring them globally is that 2.x gcc versions sometimes crash on local WINAPI function pointers.
Then I think it's better to initialize them all in the test's 'main' function. I'll submit a patch for that. -- Francois Gouget <fgouget(a)free.fr> http://fgouget.free.fr/ A black hole is just God dividing by zero.
participants (2)
-
Alexandre Julliard -
Francois Gouget