Commit 9ec70a88 authored by Dan Winship's avatar Dan Winship
Browse files

libnm: fix a g_signal_handler_find() call in NMRemoteSettings

NMRemoteSettings was looking for a signal handler on an
NMRemoteConnection using only G_SIGNAL_MATCH_FUNC, which means it
would get tripped up if a connection was known to two different
NMRemoteSettings objects at once. Although that can't happen now, it
might in the future if NMRemoteConnection became an NMObject, so use
G_SIGNAL_MATCH_DATA too.
parent f8762f7d
...@@ -358,8 +358,8 @@ connection_added (NMRemoteSettings *self, ...@@ -358,8 +358,8 @@ connection_added (NMRemoteSettings *self,
AddConnectionInfo *addinfo; AddConnectionInfo *addinfo;
const char *path; const char *path;
if (!g_signal_handler_find (remote, G_SIGNAL_MATCH_FUNC, 0, 0, NULL, if (!g_signal_handler_find (remote, G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, 0, 0, NULL,
G_CALLBACK (connection_visible_changed), NULL)) { G_CALLBACK (connection_visible_changed), self)) {
g_signal_connect (remote, g_signal_connect (remote,
"notify::" NM_REMOTE_CONNECTION_VISIBLE, "notify::" NM_REMOTE_CONNECTION_VISIBLE,
G_CALLBACK (connection_visible_changed), G_CALLBACK (connection_visible_changed),
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment