]> git.0d.be Git - empathy.git/commitdiff
Handle new NM 0.9 states (#644412)
authorDan Williams <dcbw@redhat.com>
Tue, 22 Mar 2011 09:04:24 +0000 (10:04 +0100)
committerGuillaume Desmottes <guillaume.desmottes@collabora.co.uk>
Tue, 22 Mar 2011 09:04:24 +0000 (10:04 +0100)
libempathy/empathy-connectivity.c

index 42d5fcc1f6a562c5988b63b82000a15fbd810d16..ebd72b09d7fc39707ad191ce413367fa9668d222 100644 (file)
@@ -87,6 +87,11 @@ connectivity_change_state (EmpathyConnectivity *connectivity,
 }
 
 #ifdef HAVE_NM
+
+#if !defined(NM_CHECK_VERSION)
+#define NM_CHECK_VERSION(x,y,z) 0
+#endif
+
 static void
 connectivity_nm_state_change_cb (NMClient *client,
     const GParamSpec *pspec,
@@ -103,6 +108,9 @@ connectivity_nm_state_change_cb (NMClient *client,
 
   state = nm_client_get_state (priv->nm_client);
   new_nm_connected = !(state == NM_STATE_CONNECTING
+#if NM_CHECK_VERSION(0,8,992)
+      || state == NM_STATE_DISCONNECTING
+#endif
       || state == NM_STATE_DISCONNECTED);
 
   DEBUG ("New NetworkManager network state %d (connected: %s)", state,