Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 453cab62 authored by Sam Mortimer's avatar Sam Mortimer
Browse files

lineage-sdk: Fix traffic stats for tethering and vpn use cases

Problems with current TrafficStats.getTotal[RT]XBytes()
implementation:

* Tethering related traffic is not counted at all.

* If you have a VPN active, stats are double counted.

So change the approach and track traffic on all non-VPN Internet
capable networks since:

* Tethering traffic is included in interface specific stats
  (unlike getTotal*).

* VPN networks are excluded so no longer double counted.

* Works correctly regardless of hotspot "Allow clients to use
  VPNs" hotspot setting.

* Works with simultaneous wifi ap and wifi upstream.
  (WIFI_HIDL_FEATURE_DUAL_INTERFACE = true)

Change-Id: Ic1135f10388b5be427202b092acd1444f94bd2b6
parent 9b69fd9c
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment