mirror of
https://github.com/mackron/miniaudio.git
synced 2026-04-23 16:54:03 +02:00
Fix a subtle memory leak.
This commit is contained in:
@@ -7040,7 +7040,7 @@ early_exit:
|
|||||||
} else {
|
} else {
|
||||||
/* Loading asynchronously. We may need to wait for initialization. */
|
/* Loading asynchronously. We may need to wait for initialization. */
|
||||||
if ((flags & MA_DATA_SOURCE_FLAG_WAIT_INIT) != 0) {
|
if ((flags & MA_DATA_SOURCE_FLAG_WAIT_INIT) != 0) {
|
||||||
ma_resource_manager_inline_notification_wait_and_uninit(&initNotification);
|
ma_resource_manager_inline_notification_wait(&initNotification);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -7054,6 +7054,10 @@ done:
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if ((flags & MA_DATA_SOURCE_FLAG_WAIT_INIT) != 0) {
|
||||||
|
ma_resource_manager_inline_notification_uninit(&initNotification);
|
||||||
|
}
|
||||||
|
|
||||||
*ppDataBufferNode = pDataBufferNode;
|
*ppDataBufferNode = pDataBufferNode;
|
||||||
|
|
||||||
return result;
|
return result;
|
||||||
|
|||||||
Reference in New Issue
Block a user