Persona is no longer an option for authentication on BMO. For more details see Persona Deprecated.
Last Comment Bug 624338 - Update check for default browser to work the new way (glib >= 2.27.1)
: Update check for default browser to work the new way (glib >= 2.27.1)
[fixed in bug 611953]
Product: Firefox
Classification: Client Software
Component: Shell Integration (show other bugs)
: Trunk
: All Linux
: -- normal (vote)
: Firefox 6
Assigned To: Nobody; OK to take it and work on it
: Robert Strong [:rstrong] (use needinfo to contact me)
Depends on: 611953
  Show dependency treegraph
Reported: 2011-01-10 02:17 PST by Vincent Untz
Modified: 2011-05-03 21:17 PDT (History)
6 users (show)
See Also:
Crash Signature:
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Description Vincent Untz 2011-01-10 02:17:12 PST
User-Agent:       Mozilla/5.0 (X11; U; Linux i686; fr-fr) AppleWebKit/534.7+ (KHTML, like Gecko) Version/5.0 Safari/534.7+ SUSE/11.4 (2.30.6-97.5) Epiphany/2.30.6
Build Identifier: 

Starting with glib 2.27.1, the way for an app to declare that it supports opening a URI scheme has changed: it used to be something living in gconf, and now we use the mime system with a mime type like x-scheme-handler/http. The old way doesn't work anymore.

glib 2.27/2.28 will be used in all distributions releasing in spring 2011.

See and the first part of for some more background.

So Firefox needs to be updated for this:

a) appProtocols ( should have mime types for each of the protocol. It's always something like x-scheme-handler/http.

b) nsGNOMEShellService::IsDefaultBrowser (from needs to use g_app_info_get_default_for_type() ( with x-scheme-handler/http and others to know what's the default app. You can then use g_app_info_get_executable() ( to see if the app matches argv[0].

c) nsGNOMEShellService::SetDefaultBrowser (from needs to also be updated. Instead of calling gconf->SetAppForProtocol(), you can simply call appInfo->SetAsDefaultForMimeType() for x-scheme-handler/http, like you do later for the usual mime types.

It's worth pointing out that shipping a desktop file with Firefox (say MozillaFirefox.desktop) would make things a bit cleaner. Instead of using g_app_info_get_executable() and checking the name of the binary, you could use g_app_info_get_id() and check that it returns MozillaFirefox.desktop. You also wouldn't need to create a GAppInfo from nothing with giovfs->CreateAppFromCommand in nsGNOMEShellService::SetDefaultBrowser(). You could instead just create it with g_desktop_app_info_new().

Reproducible: Always
Comment 1 Wolfgang Rosenauer [:wolfiR] 2011-01-10 02:30:56 PST
I might pick that up in the near future. If anyone else wants to look at it earlier let me know.
Comment 2 Christopher Aillon (sabbatical, not receiving bugmail) 2011-01-11 11:04:33 PST
also see bug 611953
Comment 3 Karl Tomlinson (:karlt) 2011-05-03 21:03:58 PDT
This should be addressed by

That implementation used g_app_info_get_default_for_uri_scheme instead of g_app_info_get_default_for_type.

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