diff options
| author | Joakim Verona | 2012-09-10 16:03:53 +0200 |
|---|---|---|
| committer | Joakim Verona | 2012-09-10 16:03:53 +0200 |
| commit | b035a30e5cd2f34fedc04c253eeb5a11afed8145 (patch) | |
| tree | b9350cce389602f4967bdc1beed745929155ad5d /src/gtkutil.c | |
| parent | 4a37733c693d59a9b83a3fb2d0c7f9461d149f60 (diff) | |
| parent | a31a4cdacb196cc96dcb9bd229edb1d635e01344 (diff) | |
| download | emacs-b035a30e5cd2f34fedc04c253eeb5a11afed8145.tar.gz emacs-b035a30e5cd2f34fedc04c253eeb5a11afed8145.zip | |
upstream
Diffstat (limited to 'src/gtkutil.c')
| -rw-r--r-- | src/gtkutil.c | 23 |
1 files changed, 14 insertions, 9 deletions
diff --git a/src/gtkutil.c b/src/gtkutil.c index f0d2c022f0c..884574e1062 100644 --- a/src/gtkutil.c +++ b/src/gtkutil.c | |||
| @@ -21,7 +21,6 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */ | |||
| 21 | 21 | ||
| 22 | #ifdef USE_GTK | 22 | #ifdef USE_GTK |
| 23 | #include <float.h> | 23 | #include <float.h> |
| 24 | #include <signal.h> | ||
| 25 | #include <stdio.h> | 24 | #include <stdio.h> |
| 26 | #include <setjmp.h> | 25 | #include <setjmp.h> |
| 27 | 26 | ||
| @@ -254,7 +253,7 @@ void | |||
| 254 | free_widget_value (widget_value *wv) | 253 | free_widget_value (widget_value *wv) |
| 255 | { | 254 | { |
| 256 | if (wv->free_list) | 255 | if (wv->free_list) |
| 257 | abort (); | 256 | emacs_abort (); |
| 258 | 257 | ||
| 259 | if (malloc_cpt > 25) | 258 | if (malloc_cpt > 25) |
| 260 | { | 259 | { |
| @@ -1979,7 +1978,10 @@ xg_get_file_name (FRAME_PTR f, | |||
| 1979 | /* I really don't know why this is needed, but without this the GLIBC add on | 1978 | /* I really don't know why this is needed, but without this the GLIBC add on |
| 1980 | library linuxthreads hangs when the Gnome file chooser backend creates | 1979 | library linuxthreads hangs when the Gnome file chooser backend creates |
| 1981 | threads. */ | 1980 | threads. */ |
| 1982 | sigblock (sigmask (__SIGRTMIN)); | 1981 | sigset_t blocked; |
| 1982 | sigemptyset (&blocked); | ||
| 1983 | sigaddset (&blocked, __SIGRTMIN); | ||
| 1984 | pthread_sigmask (SIG_BLOCK, &blocked, 0); | ||
| 1983 | #endif /* HAVE_PTHREAD */ | 1985 | #endif /* HAVE_PTHREAD */ |
| 1984 | 1986 | ||
| 1985 | #ifdef HAVE_GTK_FILE_SELECTION_NEW | 1987 | #ifdef HAVE_GTK_FILE_SELECTION_NEW |
| @@ -2001,7 +2003,7 @@ xg_get_file_name (FRAME_PTR f, | |||
| 2001 | filesel_done = xg_dialog_run (f, w); | 2003 | filesel_done = xg_dialog_run (f, w); |
| 2002 | 2004 | ||
| 2003 | #if defined (HAVE_PTHREAD) && defined (__SIGRTMIN) | 2005 | #if defined (HAVE_PTHREAD) && defined (__SIGRTMIN) |
| 2004 | sigunblock (sigmask (__SIGRTMIN)); | 2006 | pthread_sigmask (SIG_UNBLOCK, &blocked, 0); |
| 2005 | #endif | 2007 | #endif |
| 2006 | 2008 | ||
| 2007 | if (filesel_done == GTK_RESPONSE_OK) | 2009 | if (filesel_done == GTK_RESPONSE_OK) |
| @@ -2057,7 +2059,10 @@ xg_get_font (FRAME_PTR f, const char *default_name) | |||
| 2057 | Lisp_Object font = Qnil; | 2059 | Lisp_Object font = Qnil; |
| 2058 | 2060 | ||
| 2059 | #if defined (HAVE_PTHREAD) && defined (__SIGRTMIN) | 2061 | #if defined (HAVE_PTHREAD) && defined (__SIGRTMIN) |
| 2060 | sigblock (sigmask (__SIGRTMIN)); | 2062 | sigset_t blocked; |
| 2063 | sigemptyset (&blocked); | ||
| 2064 | sigaddset (&blocked, __SIGRTMIN); | ||
| 2065 | pthread_sigmask (SIG_BLOCK, &blocked, 0); | ||
| 2061 | #endif /* HAVE_PTHREAD */ | 2066 | #endif /* HAVE_PTHREAD */ |
| 2062 | 2067 | ||
| 2063 | w = gtk_font_chooser_dialog_new | 2068 | w = gtk_font_chooser_dialog_new |
| @@ -2086,7 +2091,7 @@ xg_get_font (FRAME_PTR f, const char *default_name) | |||
| 2086 | done = xg_dialog_run (f, w); | 2091 | done = xg_dialog_run (f, w); |
| 2087 | 2092 | ||
| 2088 | #if defined (HAVE_PTHREAD) && defined (__SIGRTMIN) | 2093 | #if defined (HAVE_PTHREAD) && defined (__SIGRTMIN) |
| 2089 | sigunblock (sigmask (__SIGRTMIN)); | 2094 | pthread_sigmask (SIG_UNBLOCK, &blocked, 0); |
| 2090 | #endif | 2095 | #endif |
| 2091 | 2096 | ||
| 2092 | if (done == GTK_RESPONSE_OK) | 2097 | if (done == GTK_RESPONSE_OK) |
| @@ -3519,7 +3524,7 @@ xg_store_widget_in_map (GtkWidget *w) | |||
| 3519 | } | 3524 | } |
| 3520 | 3525 | ||
| 3521 | /* Should never end up here */ | 3526 | /* Should never end up here */ |
| 3522 | abort (); | 3527 | emacs_abort (); |
| 3523 | } | 3528 | } |
| 3524 | 3529 | ||
| 3525 | /* Remove pointer at IDX from id_to_widget. | 3530 | /* Remove pointer at IDX from id_to_widget. |
| @@ -4087,7 +4092,7 @@ xg_tool_bar_menu_proxy (GtkToolItem *toolitem, gpointer user_data) | |||
| 4087 | else | 4092 | else |
| 4088 | { | 4093 | { |
| 4089 | fprintf (stderr, "internal error: GTK_IMAGE_PIXBUF failed\n"); | 4094 | fprintf (stderr, "internal error: GTK_IMAGE_PIXBUF failed\n"); |
| 4090 | abort (); | 4095 | emacs_abort (); |
| 4091 | } | 4096 | } |
| 4092 | } | 4097 | } |
| 4093 | else if (store_type == GTK_IMAGE_ICON_NAME) | 4098 | else if (store_type == GTK_IMAGE_ICON_NAME) |
| @@ -4102,7 +4107,7 @@ xg_tool_bar_menu_proxy (GtkToolItem *toolitem, gpointer user_data) | |||
| 4102 | else | 4107 | else |
| 4103 | { | 4108 | { |
| 4104 | fprintf (stderr, "internal error: store_type is %d\n", store_type); | 4109 | fprintf (stderr, "internal error: store_type is %d\n", store_type); |
| 4105 | abort (); | 4110 | emacs_abort (); |
| 4106 | } | 4111 | } |
| 4107 | } | 4112 | } |
| 4108 | if (wmenuimage) | 4113 | if (wmenuimage) |