Bug 1483942 - Emacs crashing while connecting via Windows with X11 forwarding
Summary: Emacs crashing while connecting via Windows with X11 forwarding
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: gtk3
Version: 7.4
Hardware: x86_64
OS: Linux
urgent
urgent
Target Milestone: rc
: ---
Assignee: Benjamin Otte
QA Contact: Desktop QE
URL:
Whiteboard:
Depends On:
Blocks: 1549982
TreeView+ depends on / blocked
 
Reported: 2017-08-22 10:43 UTC by jigar
Modified: 2018-05-17 14:39 UTC (History)
24 users (show)

Fixed In Version: gtk3-3.22.26-3.el7
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 1549982 (view as bug list)
Environment:
Last Closed: 2018-04-10 13:02:20 UTC
Target Upstream Version:


Attachments (Terms of Use)
Sample xdpyinfo output requested by M. Clasen (7.28 KB, text/plain)
2017-11-03 18:41 UTC, Andy Gruss
no flags Details
x11: Don't call XInput API for core events (1.08 KB, patch)
2018-02-12 20:44 UTC, Ray Strode [halfline]
no flags Details | Diff


Links
System ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2018:0770 normal SHIPPED_LIVE gtk3, gdm, gnome-shell, gnome-session update, new packages: wayland 2018-05-24 21:57:33 UTC
Red Hat Knowledge Base (Solution) 3410101 None None None 2018-04-12 14:00:03 UTC

Description jigar 2017-08-22 10:43:06 UTC
Description of problem: 

Emacs is crashing over X11 forwarding when connected using Windows. Following is the backtrace :


[root@localhost ~]# emacs &
[1] 18679
[root@localhost ~]# X protocol error: BadRequest (invalid request code or no such operation) on protocol request 130
When compiled with GTK, Emacs cannot recover from X disconnects.
This is a GTK bug: https://bugzilla.gnome.org/show_bug.cgi?id=85715
For details, see etc/PROBLEMS.

Backtrace:
emacs[0x4f98c3]
emacs[0x4deef1]
emacs[0x4f9903]
emacs[0x4b339b]
emacs[0x4b560c]
emacs[0x4b566d]
/lib64/libX11.so.6(_XError+0x12b)[0x7fccda6f107b]
/lib64/libX11.so.6(+0x420d7)[0x7fccda6ee0d7]
/lib64/libX11.so.6(+0x42195)[0x7fccda6ee195]
/lib64/libX11.so.6(_XReply+0x208)[0x7fccda6ef088]
/lib64/libX11.so.6(XQueryPointer+0x8e)[0x7fccda6e50be]
...

You have new mail in /var/spool/mail/root
[1]+  Aborted                 (core dumped) emacs


Version-Release number of selected component (if applicable): gtk3-3.22.10-4


How reproducible: Always


Steps to Reproduce:
1. Connect to RHEL-7.4 via Windows system with X11 forwarding enabled
2. Run $ emacs &
3. Move the mouse cursor in the emacs window/ wait for a few seconds

Actual results: Emacs crashes 

Expected results: Emacs should not crash

Additional info:
1) This wasn't reproducible with RHEL-7.3, so it seems to be a regression bug.
2) While crashing, following bug was suggested : https://bugzilla.gnome.org/show_bug.cgi?id=85715

Comment 2 Darren 2017-10-03 15:29:38 UTC
I have discovered the same issue, with the same error results. Is there a workaround for this until the issue is fixed?

Comment 3 Victor Andreasson 2017-10-11 12:39:36 UTC
I can confirm this bug on RHEL-7.4 and emacs 24.3-20.el7_4. It's affecting many of our developers.

Comment 7 Matthias Clasen 2017-11-01 12:55:05 UTC
The upstream bug is not relevant - closing displays has not worked for a very long time, it is certainly not a 7.3-74 regression.

The description "crashing over X11 forwarding when connected using Windows." is a little unclear:

- What is the role of Windows here ?
- Is this a Windows X server ? If so, which one ?
- Can we get the output of xdpyinfo --ext all, please ?

The stacktrace is not detailed enough to say much.

Comment 9 Andy Gruss 2017-11-03 18:41:44 UTC
Created attachment 1347519 [details]
Sample xdpyinfo output requested by M. Clasen

Comment 10 Andy Gruss 2017-11-03 18:43:37 UTC
(In reply to Matthias Clasen from comment #7)
> The description "crashing over X11 forwarding when connected using Windows."
> is a little unclear:
> 
> - What is the role of Windows here ?
        Display.
> - Is this a Windows X server ? If so, which one ?
        Yes.  VcXsrv.exe (X2Go/Arctica Builds) v1.17.0.0-3.  Also,
        same issue reproduced by jigar using the Xming Windows X
        server.
> - Can we get the output of xdpyinfo --ext all, please ?
        See attachment.

Comment 11 Darren 2017-11-03 21:21:17 UTC
I am using it in the same manner, but using XMing. No screen shot available.

Comment 18 Yu Wang 2018-01-25 15:45:41 UTC
Emacs crashes with X11 tunneling through XMing when our servers run 3.10.0-693.11.1.el7.x86_64 kernel. After we rolled back to 3.10.0-514.10.2.el7.x86_64, emacs runs fine.

Comment 19 Piyush Bhoot 2018-01-30 17:44:43 UTC
(In reply to Yu Wang from comment #18)
> Emacs crashes with X11 tunneling through XMing when our servers run
> 3.10.0-693.11.1.el7.x86_64 kernel. After we rolled back to
> 3.10.0-514.10.2.el7.x86_64, emacs runs fine.

What is gtk and emacs version at your end? not working on my end even after downgrading to 3.10.0-514.10.2.el7.x86_64,

Comment 21 Piyush Bhoot 2018-01-31 16:22:28 UTC
Issue seems confined to xming ; mobaxterm does not result any crash

Comment 22 Yu Wang 2018-01-31 17:28:36 UTC
(In reply to Piyush Bhoot from comment #21)
> Issue seems confined to xming ; mobaxterm does not result any crash

I was about to post the same finding:

"I spoke too soon. Emacs crashed yesterday on servers I downgraded to 3.10.0-514.10..el7.x86_64. So I tried a few other things and found one that works:

I replaced Xming with MobaXterm. Emacs has been running for a good two hours."

Comment 23 ptoshniw 2018-01-31 17:34:35 UTC
Yes, it seems to be running well with MobaXterm.

Comment 27 Adrian Marsh 2018-02-08 14:34:58 UTC
Hi,

I'd like to get an update of the ETA on this.  Its listed as Critical but was opened back in August.

I'm about to be upgrading 1000s of hosts up to RHEL7.4, as early as this weekend and so this could impact our users.  The workaround above of using MobaXterm is not an option for us.

I've tried an alias :

alias emacstest='XLIB_SKIP_ARGB_VISUALS=1 emacs'

but thats not constantly helped.

So far only a private build with "--with-x-toolkit=gtk2" as per 1349412 seems to of worked for us, but thats not a great supportable solution.

Just talking to our redhat engineer in our case 02030623 they've recommended we stay at RHEL7.3, however thats not practical for us now, nor does it help with other vulnerabilities.

Comment 29 Ray Strode [halfline] 2018-02-12 20:44:11 UTC
Created attachment 1395089 [details]
x11: Don't call XInput API for core events

Benjamin did this patch, which should hopefully address the issue.

Comment 41 errata-xmlrpc 2018-04-10 13:02:20 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2018:0770


Note You need to log in before you can comment on or make changes to this bug.