Skip to content

Conversation

@stephentoub
Copy link
Member

SoundPlayer assumes that a Read on a stream will return everything asked for, and that's not the case.

Fixes #80264

@ghost ghost assigned stephentoub Feb 24, 2023
SoundPlayer assumes that a Read on a stream will return everything asked for, and that's not the case.
@ghost
Copy link

ghost commented Feb 24, 2023

Tagging subscribers to this area: @dotnet/area-microsoft-win32
See info in area-owners.md if you want to be subscribed.

Issue Details

SoundPlayer assumes that a Read on a stream will return everything asked for, and that's not the case.

Fixes #80264

Author: stephentoub
Assignees: stephentoub
Labels:

area-Microsoft.Win32

Milestone: -

@stephentoub stephentoub merged commit b61bdb9 into dotnet:main Mar 2, 2023
@stephentoub stephentoub deleted the fixsoundplayerreads branch March 2, 2023 17:02
_stream.Read(_streamData, 0, streamLen);
#if NET7_0_OR_GREATER
_stream.ReadExactly(_streamData);
#else
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we backport this?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ghost ghost locked as resolved and limited conversation to collaborators Apr 1, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

SoundPlayer from Stream doesn't work for partial reads

3 participants