OpenXDK XAudio does not deinitialize itself

Open
#363 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
30/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Stale
Tech stack
c

Research direction

Start by investigating issue #362, as the report says calling XAudioInit shortly before shutdown appears to hide that issue. Then trace XAudio shutdown and AC97 initialization to identify where a shutdown handler should be registered and what deinitialization must release. Done means audio buffers are cleaned up at shutdown without leaks or garbage playback.

Written by the indexing model from the issue text.

Description

xaudio leaks memory; it also plays garbage while the application is quitting (because it will keep buffers alive, but they'll be overwritten / free'd by the kernel or next application).

A shutdown handler should be registered and a function for de-initializing AC97 should be added.

We should probably investigate #362 first, because even just calling XAudioInit shortly before shutting down actually seems to hide that issue.

Dominant language
C
Stars
600
Forks
97
Avg merge
11h 48m
Merged PRs (30d)
2

Getting set up

  • Ships a Dockerfile or Docker Compose file
  • No pull request template
  • No contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from XboxDev/nxdk

All issues in XboxDev/nxdk

Similar issues

More C issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.