summaryrefslogtreecommitdiff
path: root/src/xmenu.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/xmenu.c')
-rw-r--r--src/xmenu.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/xmenu.c b/src/xmenu.c
index a6762236bc4..ea2cbab2030 100644
--- a/src/xmenu.c
+++ b/src/xmenu.c
@@ -1603,6 +1603,14 @@ x_menu_show (struct frame *f, int x, int y, int menuflags,
STRINGP (help) ? help : Qnil);
if (prev_wv)
prev_wv->next = wv;
+ else if (!save_wv)
+ {
+ /* This emacs_abort call pacifies gcc 11.2.1 when Emacs
+ is configured with --enable-gcc-warnings. FIXME: If
+ save_wv can be null, do something better; otherwise,
+ explain why save_wv cannot be null. */
+ emacs_abort ();
+ }
else
save_wv->contents = wv;
if (!NILP (descrip))