cppcheck sept 18 redux
Ben Klein
shacklein at gmail.com
Tue Sep 22 09:03:58 CDT 2009
2009/9/22 Vitaliy Margolen <wine-devel at kievinfo.com>:
> Mike Kaplinskiy wrote:
>> It actually does not dereference anything. Try passing null into the
>> function - it will work just fine. This is a special case because the
>> array isn't dynamically allocated but is part of the struct, which
>> means that dmW->dmFormName == (dmW+__offset of dmFormName) and not
>> *(dmW+__offset of dmFormName). You can try writing a test program
>> yourself - it will run just fine.
> It does dereference the pointer. Here is your simple test. Compile it and
> run it. See what happens.
>
> #include <stdio.h>
>
> typedef struct _s_test
> {
> void *pointer;
No. Array, not pointer. E.g.:
int array[1];
> } s_test;
More information about the wine-devel
mailing list