Bug 460475

Summary: metacity + emacs: desktop freeze
Product: [openSUSE] openSUSE 11.1 Reporter: Juergen Weigert <jw>
Component: GNOMEAssignee: E-mail List <gnome-bugs>
Status: RESOLVED INVALID QA Contact: E-mail List <qa-bugs>
Severity: Critical    
Priority: P2 - High CC: federico, mgorse, michael.meeks, sbrabec, sshaw, vuntz, werner
Version: Final   
Target Milestone: ---   
Hardware: Other   
OS: Other   
Whiteboard:
Found By: --- Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---
Bug Depends on:    
Bug Blocks: 357354    

Description Juergen Weigert 2008-12-19 00:51:40 UTC
while moving windows around with the mouse, suddenly the entire desktop freezes.
Only the mousecursor moves. Focus remains in one window.

Happened the second time now, and the focus was in an xterm, so I was able to investigate. Killing metacity with SIGTERM causes metacity to respawn, and the desktop refreshes and is usable again.

I did not see this in SLED-11-beta6.
Comment 1 Vincent Untz 2009-01-21 13:15:23 UTC
It seems you can reproduce. Can you:

 + launch metacity from a terminal so that you see important errors?
 + and also launch it this way: http://blogs.gnome.org/metacity/2008/03/07/logging/
 + when this is happening, does metacity eat your cpu?
 + can you possibly attach to it with gdb and print the current stack trace?
   (we'd need debug packages to be installed)

FWIW, I've never seen this :/ Are you using sloppy focus, or some non-default config option in metacity?
Comment 2 Federico Mena Quintero 2009-02-11 16:25:37 UTC
I've seen Metacity hang in a CORBA call to at-spi when hitting Alt-Tab in Emacs.  This seems to be new in 11.1.
Comment 3 JP Rosevear 2009-02-12 19:28:09 UTC
This is not wide spread and a11y is not on by default.
Comment 4 Federico Mena Quintero 2009-02-17 17:35:12 UTC
This is where at-spi-registryd hangs:

#0  0xffffe430 in __kernel_vsyscall ()
#1  0xb729a66b in poll () from /lib/libc.so.6
#2  0xb750def2 in ?? () from /usr/lib/libglib-2.0.so.0
#3  0xb750e221 in g_main_context_iteration () from /usr/lib/libglib-2.0.so.0
#4  0xb7e68997 in link_main_iteration () from /usr/lib/libORBit-2.so.0
#5  0xb7e4afbe in giop_recv_buffer_get () from /usr/lib/libORBit-2.so.0
#6  0xb7e50086 in ORBit_small_invoke_stub () from /usr/lib/libORBit-2.so.0
#7  0xb7e502b9 in ORBit_small_invoke_stub_n () from /usr/lib/libORBit-2.so.0
#8  0xb7e5cf3a in ORBit_c_stub_invoke () from /usr/lib/libORBit-2.so.0
#9  0xb7e9780f in Bonobo_Unknown_unref () from /usr/lib/libbonobo-activation.so.4
#10 0xb7ecd647 in bonobo_object_release_unref () from /usr/lib/libbonobo-2.so.0
#11 0x080513c3 in registry_flush_event_queue (registry=0x8060410, discard=0, ev=0xbfbb190c) at registry.c:751
#12 0x0805175b in registry_filter_event (registry=0x8060410, ctx=0xbfbb1694, ev=0xbfbb190c) at registry.c:924
#13 0x080517ea in impl_registry_notify_event (servant=0x8060424, e=0x80965a4, ev=0xbfbb190c) at registry.c:954
#14 0xb7f5d49c in _ORBIT_skel_small_Accessibility_EventListener_notifyEvent (_o_servant=0x8060424, _o_retval=0x0, _o_args=0xbfbb1760, 
    _o_ctx=0xbfbb17f8, _o_ev=0xbfbb190c, _impl_notifyEvent=0x8051776 <impl_registry_notify_event>) at Accessibility-common.c:240
#15 0xb7e5ccb7 in ?? () from /usr/lib/libORBit-2.so.0
#16 0xb7e63245 in ORBit_OAObject_invoke () from /usr/lib/libORBit-2.so.0
#17 0xb7e4f693 in ORBit_small_invoke_adaptor () from /usr/lib/libORBit-2.so.0
#18 0xb7e60d39 in ?? () from /usr/lib/libORBit-2.so.0
#19 0xb7e61412 in ?? () from /usr/lib/libORBit-2.so.0
#20 0xb7e615c9 in ?? () from /usr/lib/libORBit-2.so.0
#21 0xb7e63692 in ORBit_handle_request () from /usr/lib/libORBit-2.so.0
#22 0xb7e4ba25 in giop_connection_handle_input () from /usr/lib/libORBit-2.so.0
#23 0xb7e6ae33 in ?? () from /usr/lib/libORBit-2.so.0
#24 0xb7e6d716 in ?? () from /usr/lib/libORBit-2.so.0
#25 0xb750a9a8 in g_main_context_dispatch () from /usr/lib/libglib-2.0.so.0
#26 0xb750e063 in ?? () from /usr/lib/libglib-2.0.so.0
#27 0xb750e582 in g_main_loop_run () from /usr/lib/libglib-2.0.so.0
#28 0xb7ec8003 in bonobo_main () from /usr/lib/libbonobo-2.so.0

It's waiting for some remote object to unref itself; no idea what the object is.

I can reproduce this reliably by hitting Alt-Tab while in Emacs.
Comment 5 Federico Mena Quintero 2009-02-17 18:03:30 UTC
CCing Stephen and Michael.  Guys, do you know how I could figure out what's hanging when at-spi-registryd unrefs it?  Please see the stack trace above.
Comment 6 Jared Allen 2009-02-18 18:02:24 UTC
-> Marco
Comment 7 Stanislav Brabec 2009-06-23 12:17:51 UTC
I am consistently able to reproduce in the Factory. It appears every time. I have accessibility enabled, metacity is configured to Select windows when the mouse moves over them. No other windows than Emacs freeze.

The freeze appears while using Metacity shortcuts for Move desktop to left/right or Move window one desktop left/right or Alt+Tab and the window is above Emacs edit area. The Alt+Tab and Move desktop to left/right freeze appear even if the window is active but the pointer is above the window frame or even outside the window (e. g. above the panel).

Ctrl+Alt+F1, Ctrl+Alt+F7 works-around this grab.

There is no console output. But as far as I remember, when accessibility was off then Emacs was freezing and complaining (I can retest it in the current Factory).

There is no CPU activity of Emacs nor Metacity, but there is minor CPU activity of at-spi-registryd (<1%).

Similar bugs from the past: GNOME: bug 299919, bug 60777, KDE: bug 345669.
Comment 8 Stanislav Brabec 2009-06-23 14:33:28 UTC
I just retested Metacity + Emacs in Factory with accessibility disabled. There is no freeze and no messages on the console.
Comment 9 Federico Mena Quintero 2009-06-23 16:36:15 UTC
Moving this bug to openSUSE 11.1 to make it public.
Comment 10 Federico Mena Quintero 2015-08-20 15:30:04 UTC
Closing as obsolete.