Cache and delete old ConversationsDbusInterfaces to avoid memory leak
Summary:
After using the ConversationsDbusInterface for a little while, there can be significant (MBs) memory usage of cached messages. The QDBusAbstractAdaptor does not like to be manually deleted, but it looks like it is safe to do so after constructing a new one
This contradicts the comment in the BatteryPlugin and the BatteryDbusInterface, which says deletelater() is not safe. Has Qt been updated since then?
Test Plan:
- Run daemon
- Hopefully experience no crashes after many phone reconnects
Reviewers: KDE Connect, apol, albertvaka
Reviewed By: KDE Connect, apol, albertvaka
Subscribers: apol, kdeconnect
Tags: KDE Connect
Differential Revision: https://phabricator.kde.org/D16553