2012-07-03 14:27:33 +02:00
|
|
|
--- src/xmenu.c
|
2013-05-22 16:11:49 +02:00
|
|
|
+++ src/xmenu.c 2013-05-21 15:42:44.917439139 +0000
|
|
|
|
@@ -953,7 +953,7 @@ set_frame_menubar (FRAME_PTR f, bool fir
|
2012-07-03 14:27:33 +02:00
|
|
|
{
|
|
|
|
deep_p = 1;
|
2013-05-22 16:11:49 +02:00
|
|
|
f->output_data.x->saved_menu_event = xmalloc (sizeof (XEvent));
|
2012-07-03 14:27:33 +02:00
|
|
|
- f->output_data.x->saved_menu_event->type = 0;
|
|
|
|
+ memset(f->output_data.x->saved_menu_event,0,sizeof(XEvent));
|
|
|
|
}
|
|
|
|
|
|
|
|
#ifdef USE_GTK
|
|
|
|
--- src/xselect.c
|
|
|
|
+++ src/xselect.c 2012-07-03 11:08:10.732010284 +0000
|
2013-05-22 16:11:49 +02:00
|
|
|
@@ -2350,7 +2350,14 @@ x_fill_property_data (Display *dpy, Lisp
|
2012-07-03 14:27:33 +02:00
|
|
|
Lisp_Object o = XCAR (iter);
|
|
|
|
|
|
|
|
if (INTEGERP (o) || FLOATP (o) || CONSP (o))
|
|
|
|
- val = cons_to_signed (o, LONG_MIN, LONG_MAX);
|
|
|
|
+ {
|
|
|
|
+ if (INTEGERP (o) && (XFASTINT (o) > LONG_MAX || XFASTINT (o) < LONG_MIN))
|
|
|
|
+ val = (long) XFASTINT (o);
|
|
|
|
+ else if (FLOATP (o) && (XFLOAT_DATA (o) > LONG_MAX || XFLOAT_DATA (o) < LONG_MIN))
|
|
|
|
+ val = (long) XFLOAT_DATA (o);
|
|
|
|
+ else
|
|
|
|
+ val = cons_to_signed (o, LONG_MIN, LONG_MAX);
|
|
|
|
+ }
|
|
|
|
else if (STRINGP (o))
|
|
|
|
{
|
2013-05-22 16:11:49 +02:00
|
|
|
block_input ();
|
2012-07-03 14:27:33 +02:00
|
|
|
--- src/xterm.c
|
2013-05-22 16:11:49 +02:00
|
|
|
+++ src/xterm.c 2013-05-21 15:44:18.617938988 +0000
|
|
|
|
@@ -5764,9 +5764,11 @@ static struct x_display_info *next_noop_
|
2012-07-03 14:27:33 +02:00
|
|
|
#define SET_SAVED_BUTTON_EVENT \
|
|
|
|
do \
|
|
|
|
{ \
|
|
|
|
- if (f->output_data.x->saved_menu_event == 0) \
|
|
|
|
+ if (f->output_data.x->saved_menu_event == 0) { \
|
2013-05-22 16:11:49 +02:00
|
|
|
f->output_data.x->saved_menu_event = \
|
|
|
|
xmalloc (sizeof (XEvent)); \
|
|
|
|
+ memset(f->output_data.x->saved_menu_event,0,sizeof(XEvent)); \
|
|
|
|
+ } \
|
|
|
|
*f->output_data.x->saved_menu_event = event; \
|
2012-07-03 14:27:33 +02:00
|
|
|
inev.ie.kind = MENU_BAR_ACTIVATE_EVENT; \
|
|
|
|
XSETFRAME (inev.ie.frame_or_window, f); \
|