summaryrefslogtreecommitdiff
path: root/src/xmenu.c
diff options
context:
space:
mode:
authorPaul Eggert <eggert@cs.ucla.edu>2020-05-11 17:41:16 -0700
committerPaul Eggert <eggert@cs.ucla.edu>2020-05-11 17:54:24 -0700
commit4645430b9287c3f5ae9863d465a5dd4158e313a9 (patch)
tree6c1ca7b2cc52909d0de38ad650569352c511d948 /src/xmenu.c
parent00f0ad55cd7cbb71e42de0d52b7607ffb6a3c220 (diff)
downloademacs-4645430b9287c3f5ae9863d465a5dd4158e313a9.tar.gz
Pacify GCC 10.1.0
Pacify GCC 10.1.0 so that it does not issue false alarms when Emacs is configured with --enable-gcc-warnings. * src/dispnew.c (clear_glyph_row): * src/fns.c (hash_clear): * src/keyboard.c (append_tab_bar_item): * src/lisp.h (vcopy): * src/xfaces.c (get_lface_attributes_no_remap) (Finternal_copy_lisp_face, realize_default_face): * src/xmenu.c (set_frame_menubar): Work around -Warray-bounds false alarm in GCC 10.1.0. * src/intervals.c (copy_properties): Avoid -Wnull-dereference false alarm in GCC 10.1.0. * src/lisp.h (xvector_contents_addr, xvector_contents): New functions, useful for working around GCC bug 95072.
Diffstat (limited to 'src/xmenu.c')
-rw-r--r--src/xmenu.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/xmenu.c b/src/xmenu.c
index 9201a283b47..dba7e88f486 100644
--- a/src/xmenu.c
+++ b/src/xmenu.c
@@ -763,7 +763,7 @@ set_frame_menubar (struct frame *f, bool first_time, bool deep_p)
/* Save the frame's previous menu bar contents data. */
if (previous_menu_items_used)
- memcpy (previous_items, XVECTOR (f->menu_bar_vector)->contents,
+ memcpy (previous_items, xvector_contents (f->menu_bar_vector),
previous_menu_items_used * word_size);
/* Fill in menu_items with the current menu bar contents.