[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
master b2e6e95581: Only reset buffer-local buffer-stale-function in make
From: |
Lars Ingebrigtsen |
Subject: |
master b2e6e95581: Only reset buffer-local buffer-stale-function in make-indirect-buffer |
Date: |
Mon, 11 Jul 2022 10:08:33 -0400 (EDT) |
branch: master
commit b2e6e9558165eff1d6e51fb48cbfbc8c5f7bc1ca
Author: Lars Ingebrigtsen <larsi@gnus.org>
Commit: Lars Ingebrigtsen <larsi@gnus.org>
Only reset buffer-local buffer-stale-function in make-indirect-buffer
* src/buffer.c (Fmake_indirect_buffer): Don't set the global
buffer-stale-function (bug#48348).
---
src/buffer.c | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/src/buffer.c b/src/buffer.c
index 509ce51b55..a6d3604065 100644
--- a/src/buffer.c
+++ b/src/buffer.c
@@ -911,7 +911,8 @@ does not run the hooks `kill-buffer-hook',
set_buffer_internal_1 (b);
Fset (intern ("buffer-save-without-query"), Qnil);
Fset (intern ("buffer-file-number"), Qnil);
- Fset (intern ("buffer-stale-function"), Qnil);
+ if (!NILP (Flocal_variable_p (Qbuffer_stale_function, base_buffer)))
+ Fset (Qbuffer_stale_function, Qbuffer_stale__default_function);
/* Cloned buffers need extra setup, to do things such as deep
variable copies for list variables that might be mangled due
to destructive operations in the indirect buffer. */
@@ -6478,5 +6479,8 @@ will run for `clone-indirect-buffer' calls as well. */);
DEFSYM (Qkill_buffer__possibly_save, "kill-buffer--possibly-save");
+ DEFSYM (Qbuffer_stale_function, "buffer-stale-function");
+ DEFSYM (Qbuffer_stale__default_function, "buffer-stale--default-function");
+
Fput (intern_c_string ("erase-buffer"), Qdisabled, Qt);
}
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- master b2e6e95581: Only reset buffer-local buffer-stale-function in make-indirect-buffer,
Lars Ingebrigtsen <=