fix initial values of reallocated fluids

* libguile/threads.h:
* libguile/threads.c (scm_i_reset_fluid): New internal function, resets
  the binding of a fluid for all threads.  Needed for fluid GC.

* libguile/fluids.c (new_fluid): Call scm_i_reset_fluid here.
This commit is contained in:
Andy Wingo 2011-06-16 19:35:14 +02:00
commit 0b77014f0c
3 changed files with 24 additions and 0 deletions

View file

@ -163,6 +163,11 @@ new_fluid ()
SCM2PTR (fluid));
scm_dynwind_end ();
/* Now null out values. We could (and probably should) do this when
the fluid is collected instead of now. */
scm_i_reset_fluid (n, SCM_BOOL_F);
return fluid;
}