After thinking about it a bit more, I figured out why we can't connect
with gdbus after the fork. GDBus uses a separate thread to send and
receive the message, which is only initialized once in
gdbusprivate.c:_g_dbus_shared_thread_ref, guarded by the call to
g_once_init_enter. After the fork, that thread is gone, so when we try
to connect, no messages are sent or received, and we time out.

This can be seen by running gvim in gdb. After the fork, if you zero out
shared_thread_data and ensured_classes (to avoid an abort), gvim will
load right up and ibus will be working.

So I guess the only sane way to fix this on gvim's side would be to move
the gtk_init_check to after the fork (although it seems gvim uses that
to determine if it needs to fallback to text mode, so that may break
other things).

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/987707

Title:
  gvim in Precise can't connect to ibus and takes a long time to load

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/vim/+bug/987707/+subscriptions

-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to