diff options
| author | Ken Raeburn | 2016-12-29 20:56:31 -0500 |
|---|---|---|
| committer | Ken Raeburn | 2016-12-30 17:39:23 -0500 |
| commit | b0239945a36dafae908259a9a29c2a166ff53cee (patch) | |
| tree | 9d824e99ecaa7a9e1ae5a97518c0fb9b0e7a93d0 | |
| parent | 108ef8033be79e9e5567002e85a316ecb5e77cad (diff) | |
| download | emacs-b0239945a36dafae908259a9a29c2a166ff53cee.tar.gz emacs-b0239945a36dafae908259a9a29c2a166ff53cee.zip | |
Initialize thread support for Xlib.
* src/xterm.c (x_initialize) [THREADS_ENABLED]: Call XInitThreads
before doing anything else with X.
| -rw-r--r-- | src/xterm.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/xterm.c b/src/xterm.c index bdc21e6de02..67bd13a042f 100644 --- a/src/xterm.c +++ b/src/xterm.c | |||
| @@ -12762,6 +12762,13 @@ x_initialize (void) | |||
| 12762 | /* Try to use interrupt input; if we can't, then start polling. */ | 12762 | /* Try to use interrupt input; if we can't, then start polling. */ |
| 12763 | Fset_input_interrupt_mode (Qt); | 12763 | Fset_input_interrupt_mode (Qt); |
| 12764 | 12764 | ||
| 12765 | #if THREADS_ENABLED | ||
| 12766 | /* This must be called before any other Xlib routines. */ | ||
| 12767 | if (XInitThreads () == 0) | ||
| 12768 | fprintf (stderr, | ||
| 12769 | "Warning: An error occurred initializing X11 thread support!\n"); | ||
| 12770 | #endif | ||
| 12771 | |||
| 12765 | #ifdef USE_X_TOOLKIT | 12772 | #ifdef USE_X_TOOLKIT |
| 12766 | XtToolkitInitialize (); | 12773 | XtToolkitInitialize (); |
| 12767 | 12774 | ||