[PATCH] wined3d: Reduce console flood with an Ogre3D Game

Nicolas Le Cam niko.lecam at gmail.com
Wed Jan 25 00:21:55 CST 2012


2012/1/25 Francois Gouget <fgouget at free.fr>:
> On Wed, 25 Jan 2012, Detlef Riekenberg wrote:
>
>> On Sun, 2012-01-22 at 19:53 +0100, Henri Verbeet wrote:
>> > On 22 January 2012 19:44, Detlef Riekenberg <wine.dev at web.de> wrote:
>> > > -    if (usage & ~handled)
>> > > +    static DWORD reported_once;
>> > > +
>> > > +    if (usage & ~(handled | reported_once))
>> > > +    {
>> > > +        reported_once |= (usage & ~handled);
>> > >         FIXME("Unhandled usage flags %#x.\n", usage & ~handled);
>> > > +    }
>> > I don't think so.
>>
>> Sorry, I have no Idea, what objections do you have.
>
> I don't pretend to know what Henry meant but reported_once is not
> initialized. It's probably put into a zero-initialized section by the
> compiler but it looks worrying to me (I believe something like this has
> been debated on the Linux kernel mailing list).
>
> I did not try to check the bit manipulations.
>
> --
> Francois Gouget <fgouget at free.fr>              http://fgouget.free.fr/
>               If you think the whole world revolves around you,
>                 quit staring at the GPS display while driving.
>
>

static variables are zero-initialized by default I don't think that's
the problem. Perhaps it's because with such a patch, only the first
unhandled flag will be reported and not others (wich can be of a
different value), so using a bit mask to only report once every
unhandled flags will be better ?

-- 
Nicolas Le Cam



More information about the wine-devel mailing list