On Wed, 21 Nov 2012, Jan Kiszka wrote:

> On 2012-11-21 15:08, Paolo Bonzini wrote:
> > Il 21/11/2012 15:00, Jan Kiszka ha scritto:
> >> +    if (!TlsGetValue(current_tls_index)) {
> >> +        leader = g_malloc0(sizeof(*leader));
> >> +        leader->fiber = ConvertThreadToFiber(NULL);
> >> +        TlsSetValue(current_tls_index, &leader->base);
> >>      }
> > 
> > Leaking leader is a bit bad, but it looks ok for 1.3.
> 
> Hmm. A TLS destructor is apparently not available. Is there some "on
> thread termination" callback mechanism on Windows? Didn't find one on
> first glance.
> 

Dlls receive something like THREAD_DETTACH in it's startup routine or
something like that if my memory serves me.

-- 
mailto:av1...@comtv.ru

Reply via email to