Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Memory Leak on AudioPlayer #2850

Open
alimadhoun opened this issue Jul 15, 2023 · 0 comments
Open

Memory Leak on AudioPlayer #2850

alimadhoun opened this issue Jul 15, 2023 · 0 comments
Labels

Comments

@alimadhoun
Copy link

alimadhoun commented Jul 15, 2023

macOS Version(s) Used to Build

macOS 13 Ventura

Xcode Version(s)

Xcode 14

Description

The AudioPlayer class is exhibiting a memory leak issue due to its strong relationship with the mixerNode, which is a Mixer instance, and the playerNode, which is an AVAudioPlayerNode.
This bug causes unreleased resources and potentially impacts the performance and memory usage of the application.

Steps To produce:

  • Initialize an instance of the AudioPlayer class
  • Initialize an instance of Mixer
  • Attach both the mixer and the player into some engine
  • Set the player to nil.

Expected Behavior:

The AudioPlayer class should properly release the resources associated with the playerNode and mixerNode instances when they are no longer needed, preventing memory leaks and maintaining optimal performance.

Actual Behavior:

The AudioPlayer class retains strong references to the mixerNode and playerNode instances, even when they are no longer in use. This leads to memory leaks and potentially causes increased memory usage over time.

Crash Logs, Screenshots or Other Attachments (if applicable)

Screenshot 2023-07-17 at 8 22 13 PM
@alimadhoun alimadhoun added the bug label Jul 15, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant