summaryrefslogtreecommitdiff
path: root/src/xmenu.c
diff options
context:
space:
mode:
authorKarl Heuer <kwzh@gnu.org>1995-05-02 04:50:07 +0000
committerKarl Heuer <kwzh@gnu.org>1995-05-02 04:50:07 +0000
commit13c5a27ce176a038c90598271b567713f36ab8bd (patch)
tree7ec70b55bf52c85cce4268e5876f22b61fd278f1 /src/xmenu.c
parent086d357a4364ed3365b2cecbfd2c954c9a4762e3 (diff)
downloademacs-13c5a27ce176a038c90598271b567713f36ab8bd.tar.gz
(xmenu_show, menubar_selection_callback): Move declaration
of entry to an outer block, to guarantee its value is preserved.
Diffstat (limited to 'src/xmenu.c')
-rw-r--r--src/xmenu.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/src/xmenu.c b/src/xmenu.c
index 5ac3ca80951..aaa098d55ad 100644
--- a/src/xmenu.c
+++ b/src/xmenu.c
@@ -1148,7 +1148,7 @@ menubar_selection_callback (widget, id, client_data)
LWLIB_ID id;
XtPointer client_data;
{
- Lisp_Object prefix;
+ Lisp_Object prefix, entry;
FRAME_PTR f = XFRAME (XVECTOR (frame_vector)->contents[id]);
Lisp_Object vector;
Lisp_Object *subprefix_stack;
@@ -1163,8 +1163,6 @@ menubar_selection_callback (widget, id, client_data)
i = 0;
while (i < f->menu_bar_items_used)
{
- Lisp_Object entry;
-
if (EQ (XVECTOR (vector)->contents[i], Qnil))
{
subprefix_stack[submenu_depth++] = prefix;
@@ -1840,14 +1838,12 @@ xmenu_show (f, x, y, for_click, keymaps, title, error)
the proper value. */
if (menu_item_selection != 0)
{
- Lisp_Object prefix;
+ Lisp_Object prefix, entry;
prefix = Qnil;
i = 0;
while (i < menu_items_used)
{
- Lisp_Object entry;
-
if (EQ (XVECTOR (menu_items)->contents[i], Qnil))
{
subprefix_stack[submenu_depth++] = prefix;