[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: GNOME keyring in Subclipse bug

From: Philip Martin <philip.martin_at_wandisco.com>
Date: Thu, 20 Nov 2014 12:37:28 +0000

Philip Martin <philip.martin_at_wandisco.com> writes:

> I suppose the problem might be connected to running concurrent GLIB
> event loops in two different threads. Subversion does
>
> loop = g_main_loop_new(NULL);
> g_main_loop_run(loop);
> ...
> g_main_loop_quit(loop);
>
> where NULL causes g_main_loop_new to use the default GMainContext. I
> suspect that is an error:
>
> https://tecnocode.co.uk/2014/03/27/what-is-gmaincontext/
>
> "Libraries should never use g_main_context_default() (or,
> equivalently, pass NULL to a GMainContext-typed parameter)"
>
> Perhaps we should be doing something like the patch below. It can't be
> precisely that because it doesn't work when I try it, the
> g_main_loop_run() call hangs.

gnome-keyring has a synchronous API that pushes all the event handling
into the gnome-keyring library. As well as making our code much simpler
the gnome-keyring is more likely to get it right. I've committed
r1640730. Are you able to confirm whether that fixes the problem?

-- 
Philip Martin | Subversion Committer
WANdisco // *Non-Stop Data*
Received on 2014-11-20 13:38:46 CET

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.