Release all the things
This commit is contained in:
parent
28ebc0c12b
commit
146b2d62e0
1 changed files with 5 additions and 0 deletions
|
@ -227,6 +227,11 @@ SystemvolumePlugin::SystemvolumePlugin(QObject *parent, const QVariantList &args
|
||||||
SystemvolumePlugin::~SystemvolumePlugin()
|
SystemvolumePlugin::~SystemvolumePlugin()
|
||||||
{
|
{
|
||||||
if (valid) {
|
if (valid) {
|
||||||
|
for (auto &entry : sinkList) {
|
||||||
|
entry.first->UnregisterControlChangeNotify(entry.second);
|
||||||
|
entry.second->Release();
|
||||||
|
entry.first->Release();
|
||||||
|
}
|
||||||
deviceEnumerator->UnregisterEndpointNotificationCallback(deviceCallback);
|
deviceEnumerator->UnregisterEndpointNotificationCallback(deviceCallback);
|
||||||
deviceEnumerator->Release();
|
deviceEnumerator->Release();
|
||||||
deviceEnumerator = nullptr;
|
deviceEnumerator = nullptr;
|
||||||
|
|
Loading…
Reference in a new issue