# HG changeset patch # User Andrew Innes # Date 1001886844 0 # Node ID 24530f82048e2d76890954762115529d7c1fd73a # Parent a9746e8cd6d7dc387e96825e2942c0512f9aa35f (set_frame_menubar): Take into account that f->menu_bar_vector can be nil, and not a vector. From Ken Raeburn . diff -r a9746e8cd6d7 -r 24530f82048e src/w32menu.c --- a/src/w32menu.c Sun Sep 30 10:48:42 2001 +0000 +++ b/src/w32menu.c Sun Sep 30 21:54:04 2001 +0000 @@ -1355,12 +1355,13 @@ inhibit_garbage_collection (); /* Save the frame's previous menu bar contents data. */ - bcopy (XVECTOR (f->menu_bar_vector)->contents, previous_items, - previous_menu_items_used * sizeof (Lisp_Object)); + if (previous_menu_items_used) + bcopy (XVECTOR (f->menu_bar_vector)->contents, previous_items, + previous_menu_items_used * sizeof (Lisp_Object)); /* Fill in the current menu bar contents. */ menu_items = f->menu_bar_vector; - menu_items_allocated = XVECTOR (menu_items)->size; + menu_items_allocated = VECTORP (menu_items) ? ASIZE (menu_items) : 0; init_menu_items (); for (i = 0; i < XVECTOR (items)->size; i += 4) {