diff --git a/libguile/ChangeLog b/libguile/ChangeLog index a8566b530..a7b81f2c2 100644 --- a/libguile/ChangeLog +++ b/libguile/ChangeLog @@ -1,3 +1,9 @@ +2002-07-13 Neil Jerram + + * eval.c (unmemocopy): Fix for + 1001-local-eval-error-backtrace-segfaults (unmemoization crash + with internal definitions and local-eval). + 2002-07-12 Gary Houston * dynl.c: Don't define stub procedures if DYNAMIC_LINKING is not diff --git a/libguile/eval.c b/libguile/eval.c index 172cc2e4d..68e0b78e6 100644 --- a/libguile/eval.c +++ b/libguile/eval.c @@ -1472,7 +1472,9 @@ unmemocopy (SCM x, SCM env) z = scm_cons (n, SCM_UNSPECIFIED); ls = scm_cons (scm_sym_define, z); if (!SCM_NULLP (env)) - SCM_SETCAR (SCM_CAR (env), scm_cons (n, SCM_CAAR (env))); + env = scm_cons (scm_cons (scm_cons (n, SCM_CAAR (env)), + SCM_CDAR (env)), + SCM_CDR (env)); break; } case SCM_BIT8(SCM_MAKISYM (0)):