Re: [AD] SF.net SVN: alleg:[11915] allegro/branches/4.9/src

[ Thread Index | Date Index | More lists.liballeg.org/allegro-developers Archives ]


On 2009-03-22, Milan Mimica <milan.mimica@xxxxxxxxxx> wrote:
> Peter Wang wrote:
> > On 2009-03-22, Milan Mimica <milan.mimica@xxxxxxxxxx> wrote:
> >>
> >> Probably a much better solution is to make ALLEGRO_EXTRA_DISPLAY_SETTINGS in TLS 
> >> static. This would solve the leak too.
> > 
> > Sounds good.  I'll let you decide whether to change it before or after
> > the release.
> 
> It's not simple at all. I think we should get rid of the statically initialized 
> _tls struct because it needs the nested structs to be listed there there and 
> ALLEGRO_EXTRA_DISPLAY_SETTINGS is larger than thread_local_state itself.

Can we not add an `unfilled' field to ALLEGRO_EXTRA_DISPLAY_SETTINGS,
initialise that to true, then before any operation working on an
ALLEGRO_EXTRA_DISPLAY_SETTINGS structure, check if `unfilled' is true
and call _al_fill_display_settings()?

Peter





Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/