Mercurial > emacs
changeset 34038:743849495725
(popup_get_selection): Use xmalloc instead of malloc.
author | Gerd Moellmann <gerd@gnu.org> |
---|---|
date | Thu, 30 Nov 2000 12:41:39 +0000 |
parents | 38e373eb183f |
children | 88c42020e441 |
files | src/xmenu.c |
diffstat | 1 files changed, 4 insertions(+), 8 deletions(-) [+] |
line wrap: on
line diff
--- a/src/xmenu.c Thu Nov 30 12:28:01 2000 +0000 +++ b/src/xmenu.c Thu Nov 30 12:41:39 2000 +0000 @@ -1077,14 +1077,10 @@ && (event.xany.display != dpyinfo->display || x_non_menubar_window_to_frame (dpyinfo, event.xany.window))) { - queue_tmp = (struct event_queue *) malloc (sizeof (struct event_queue)); - - if (queue_tmp != NULL) - { - queue_tmp->event = event; - queue_tmp->next = queue; - queue = queue_tmp; - } + queue_tmp = (struct event_queue *) xmalloc (sizeof *queue_tmp); + queue_tmp->event = event; + queue_tmp->next = queue; + queue = queue_tmp; } else XtDispatchEvent (&event);