1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2025-12-07 06:50:23 -08:00
emacs/lisp/emacs-lisp
Paul Eggert 083940a93d Fix core dump in substitute-object-in-subtree
Without this fix, (substitute-object-in-subtree #0=(#0# 'a) 'a)
would dump core, since the C code would recurse indefinitely through
the infinite structure.  This patch adds an argument to the function,
and renames it to lread--substitute-object-in-subtree as the function
is not general-purpose and should not be relied on by outside code.
See Bug#23660.
* src/intervals.c (traverse_intervals_noorder): ARG is now void *,
not Lisp_Object, so that callers need not cons unnecessarily.
All callers changed.  Also, remove related #if-0 code that was
“temporary” in the early 1990s and has not been compilable for
some time.
* src/lread.c (struct subst): New type, for substitution closure data.
(seen_list): Remove this static var, as this info is now part of
struct subst.  All uses removed.
(Flread__substitute_object_in_subtree): Rename from
Fsubstitute_object_in_subtree, and give it a 3rd arg so that it
doesn’t dump core when called from the top level with an
already-cyclic structure.  All callers changed.
(SUBSTITUTE): Remove.  All callers expanded and then simplified.
(substitute_object_recurse): Take a single argument SUBST rather
than a pair OBJECT and PLACEHOLDER, so that its address can be
passed around as part of a closure; this avoids the need for an
AUTO_CONS call.  All callers changed.  If the COMPLETED component
is t, treat every subobject as potentially circular.
(substitute_in_interval): Take a struct subst * rather than a
Lisp_Object, for the closure data.  All callers changed.
* test/src/lread-tests.el (lread-lread--substitute-object-in-subtree):
New test, to check that the core dump does not reoccur.
2017-07-09 16:05:13 -07:00
..
advice.el
autoload.el autoload-rubric no longer provides a feature by default 2017-05-17 12:43:23 -04:00
avl-tree.el
backquote.el Give , and .@ doc strings. Fixes bug #24561. 2017-01-23 19:00:49 +00:00
benchmark.el Use lexical binding in benchmark.el 2017-03-03 18:26:30 +09:00
bindat.el
byte-opt.el Mark keywordp as a safe, error-free function 2017-05-26 22:45:58 +01:00
byte-run.el
bytecomp.el Implement field numbers in format strings 2017-06-02 00:22:13 +02:00
cconv.el
chart.el
check-declare.el
checkdoc.el Nix some useless uses of looking-at, looking-back 2017-02-12 10:59:33 -05:00
cl-extra.el * lisp/emacs-lisp/cl-extra.el (cl--random-state): New defstruct 2017-06-30 22:01:38 -04:00
cl-generic.el Make edebug-step-in work on generic methods (Bug#22294) 2017-05-14 23:32:27 +03:00
cl-indent.el Fix cl-indent for `loop' with :keywords (Bug#15543) 2017-05-27 16:08:35 -04:00
cl-lib.el * lisp/emacs-lisp/cl-lib.el (cl-mapcar): Remove recent autoload cookie. 2017-05-04 22:26:17 -07:00
cl-macs.el Split variable macro env from function env 2017-06-07 20:03:31 -04:00
cl-preloaded.el Backward compatibility with pre-existing struct instances. 2017-04-04 08:23:46 +02:00
cl-print.el * lisp/emacs-lisp/cl-print.el (cl-print-compiled-button): t by default. 2017-07-02 11:57:34 -04:00
cl-seq.el
cl.el Move cXXXr and cXXXXr to subr.el 2017-01-25 14:21:10 -05:00
copyright.el
crm.el
cursor-sensor.el
debug.el * lisp/emacs-lisp/cl-print.el (cl-print-compiled-button): t by default. 2017-07-02 11:57:34 -04:00
derived.el
disass.el * lisp/emacs-lisp/disass.el: Fix spacing while showing jump tables 2017-01-26 14:28:23 +05:30
easy-mmode.el
easymenu.el
edebug.el Fix core dump in substitute-object-in-subtree 2017-07-09 16:05:13 -07:00
eieio-base.el Make EIEIO use records. 2017-04-04 08:23:46 +02:00
eieio-compat.el Make edebug-step-in work on generic methods (Bug#22294) 2017-05-14 23:32:27 +03:00
eieio-core.el Don't change byte-compile-delete-errors at runtime (Bug#27340) 2017-06-24 10:12:53 -04:00
eieio-custom.el
eieio-datadebug.el Use cl-print for Edebug and EIEIO 2017-02-23 22:39:53 -05:00
eieio-opt.el
eieio-speedbar.el
eieio.el * lisp/emacs-lisp/eieio.el (defclass): Fix quote in warning message. 2017-05-26 23:31:31 -04:00
eldoc.el Enable ElDoc messages after the newline command 2017-06-06 01:23:41 +03:00
elint.el Revert "Replace ldefs-boot with a much smaller file" 2017-03-07 13:49:48 +00:00
elp.el
ert-x.el New macro 'ert-with-message-capture' 2017-02-04 13:36:43 +02:00
ert.el Let test summary go through even if some logs were not generated 2017-07-01 23:42:30 -04:00
ewoc.el
find-func.el New commands: find-library-other-window, find-library-other-frame 2017-05-20 14:41:53 +03:00
float-sup.el
generator.el Remove some explicit runtime loads of pcase 2017-04-19 16:32:04 -04:00
generic.el
gv.el
helper.el
inline.el
let-alist.el ; Bump let-alist 2017-01-31 19:47:53 -05:00
lisp-mnt.el Adjust lm-verify to accept current notices 2017-06-24 17:57:56 -07:00
lisp-mode.el Fix lisp-comment-indent for single-semicolon case 2017-07-06 08:59:32 -04:00
lisp.el Modify `beginning-of-defun-comments' 2017-05-12 11:40:57 +02:00
macroexp.el
map-ynp.el
map.el
nadvice.el * lisp/emacs-lisp/cl-print.el: New file 2017-02-23 21:06:54 -05:00
package-x.el
package.el Don't put deleted packages in the trash (bug#14967) 2017-06-19 14:39:25 -04:00
pcase.el Make EIEIO use records. 2017-04-04 08:23:46 +02:00
pp.el Switch pp.el to lexical binding 2017-03-02 23:03:20 -05:00
radix-tree.el
re-builder.el Fix completing-read call in reb-change-syntax 2017-03-02 19:01:18 -05:00
regexp-opt.el
regi.el
ring.el
rx.el
seq.el * lisp/emacs-lisp/seq.el: Bump seq version. 2017-05-04 11:34:41 +02:00
shadow.el
smie.el make smie.el respect prog-first-column 2017-04-05 15:53:39 -06:00
subr-x.el Add an optional arguments to string-trim 2017-05-19 14:27:10 +03:00
syntax.el
tabulated-list.el Prevent to use tabulated-list--near-rows unbound 2017-01-22 14:23:45 +09:00
tcover-ses.el
tcover-unsafep.el
testcover.el
thunk.el Fix obsolete ‘test/automated’ references 2017-03-27 11:30:08 -07:00
timer-list.el
timer.el
tq.el
trace.el
unsafep.el
warnings.el