diff --git a/src/data.c b/src/data.c index 5711148..c8193db 100644 --- a/src/data.c +++ b/src/data.c @@ -1956,6 +1956,13 @@ struct Lisp_Symbol * BVAR (current_buffer, local_var_alist))); } + /* If the symbol forwards into a C variable, then load the binding + for this buffer now. If C code modifies the variable before we + load the binding in, then that new value will clobber the default + binding the next time we unload it. */ + if (blv->fwd) + swap_in_symval_forwarding (sym, blv); + return variable; }