telepathy-mission-control: Replace ConnMan connectivity support with GNetworkMonitor

Simon McVittie smcv at kemper.freedesktop.org
Tue Sep 3 08:15:48 PDT 2013


Module: telepathy-mission-control
Branch: master
Commit: 3ad533ac34481c4305a9093687f8042757a6cf96
URL:    http://cgit.freedesktop.org/telepathy/telepathy-mission-control/commit/?id=3ad533ac34481c4305a9093687f8042757a6cf96

Author: Simon McVittie <simon.mcvittie at collabora.co.uk>
Date:   Tue Apr 30 17:29:40 2013 +0100

Replace ConnMan connectivity support with GNetworkMonitor

The information we're getting from ConnMan is no more informative
than GNetworkMonitor, and a ConnMan GNetworkMonitor implementation
exists (e.g. <https://github.com/jukkar/connman-network-monitor>),
so we might as well go via that.

On NetworkManager systems, we now use NetworkManager to detect
transient states like DISCONNECTING, but use the GNetworkMonitor
to detect whether the interface is up. If NetworkManager is the only
thing managing an interface, that makes no difference, but if there is
an interface not managed by NetworkManager, the default netlink
GNetworkMonitor will say we're online even while NM is DISCONNECTED,
which is what we want.

On non-NetworkManager, non-ConnMan systems where netlink works,
netlink will tell us at least the basics of what's going on, and we
can avoid trying to connect while there is no Internet route.

On systems without a working GNetworkMonitor, GIO's default
implementation will say "yes, you are online" at all times, which is
no worse than we had previously.

Bug: https://bugs.freedesktop.org/show_bug.cgi?id=56635
Signed-off-by: Simon McVittie <simon.mcvittie at collabora.co.uk>
Reviewed-by: Guillaume Desmottes <guillaume.desmottes at collabora.co.uk>

---

 configure.ac                                  |   29 +----
 src/connectivity-monitor.c                    |  182 ++++++-------------------
 tests/twisted/Makefile.am                     |    7 -
 tests/twisted/account-manager/connectivity.py |    4 -
 tests/twisted/fakeconnectivity.py             |    9 +-
 5 files changed, 54 insertions(+), 177 deletions(-)

Diff:   http://cgit.freedesktop.org/telepathy/telepathy-mission-control/diff/?id=3ad533ac34481c4305a9093687f8042757a6cf96


More information about the telepathy-commits mailing list