open-uri: Avoid calling into o.fd.FileManager1 during startup
Making a synchronous call into a GTK implementation of o.fd.FileManager1 can cause a deadlock, because GtkApplication makes a synchronous call into the Inhibit portal when started in a non-GNOME, non-XFCE environment. In this situation, each service does not take its bus name (and hence complete service-activation) until it gets a reply from the other, which obviously can't work. We don't actually need a GDBusProxy here: we don't need to subscribe to any signals, watch any properties or hold any state, so it's just as straightforward to use g_dbus_connection_call_sync() on a just-in-time basis. The indentation is deliberately a bit odd here, to avoid a large diffstat from re-indentation; it will be fixed in a subsequent commit. Fixes: 69961f3f "openuri: Use FileManager1 in OpenDirectory" Resolves: https://github.com/flatpak/xdg-desktop-portal/issues/636 Signed-off-by: Simon McVittie <smcv@collabora.com>
Loading
Please register or sign in to comment