diff options
author | Marc Mutz <marc.mutz@kdab.com> | 2019-06-05 16:24:00 +0200 |
---|---|---|
committer | Marc Mutz <marc.mutz@kdab.com> | 2019-07-19 16:36:26 +0200 |
commit | cab920d52cde7053caab05fd835855c1e3d8127b (patch) | |
tree | 3ef64c2d23dbe0c33d404cfec5982e4a7eae01a2 /src/3rdparty/angle | |
parent | 34e457e873f2b699cf50ce613348e355332b9133 (diff) |
QSharedNetworkSessionManager: prune expired QNetworkSessions
Equality for QNetworkConfiguration is defined by identity of the
Private object, so even if there are QNCs with the same properties,
they will not compare equal. This probably happens when a user roams
through different WLANs (e.g. from work via public transport to home
and then back), and each time the home WLAN pops up, it will beget a
new QNetworkConfiguration, not comparing equal to the previous one.
So, over time, we might collect a sizeable amount of
QNetworkConfiguration objects just sitting in the cache without ever
being able to actually use an associated network session, because they
all have long since expired.
To fix, prune expired network sessions, and thus their associated
QNetworkConfigurations, from the cache. To not run every time, prune
only when this size of the cache is larger than 16 (arbitrary number).
Change-Id: I11a636f45ccf67420f84b1c79a4453a144de7c5c
Reviewed-by: MÃ¥rten Nordheim <marten.nordheim@qt.io>
Diffstat (limited to 'src/3rdparty/angle')
0 files changed, 0 insertions, 0 deletions