[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
master 534e631: Avoid segfault in command-modes
From: |
Basil L. Contovounesios |
Subject: |
master 534e631: Avoid segfault in command-modes |
Date: |
Sat, 4 Sep 2021 15:30:41 -0400 (EDT) |
branch: master
commit 534e631b00a3b065016df23aa0f6b7d043e9ed86
Author: Basil L. Contovounesios <contovob@tcd.ie>
Commit: Basil L. Contovounesios <contovob@tcd.ie>
Avoid segfault in command-modes
* src/data.c (Fcommand_modes): Check that bytecode object is
interactive before accessing its interactive spec to avoid
segfaulting (bug#50376).
---
src/data.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/src/data.c b/src/data.c
index ffca7e7..27b642d 100644
--- a/src/data.c
+++ b/src/data.c
@@ -1045,6 +1045,8 @@ The value, if non-nil, is a list of mode name symbols.
*/)
if (COMPILEDP (fun))
{
+ if (PVSIZE (fun) <= COMPILED_INTERACTIVE)
+ return Qnil;
Lisp_Object form = AREF (fun, COMPILED_INTERACTIVE);
if (VECTORP (form))
/* New form -- the second element is the command modes. */
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- master 534e631: Avoid segfault in command-modes,
Basil L. Contovounesios <=