-
Notifications
You must be signed in to change notification settings - Fork 845
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
(Will PR) Android WrappedPlayer
has concurrency bugs, since it is called in multiple threads, has shared fields, but without synchronizations
#1525
Labels
bug
platform-android
Affects the android platform
waiting for report
Wait for the author to respond to the conversation
Comments
Isn't the root cause the same as in #1524 ? What is the difference? You mean like the approach to solve the issue? |
Gustl22
added
waiting for report
Wait for the author to respond to the conversation
platform-android
Affects the android platform
labels
May 30, 2023
Yes and no.
|
So we should solve this issue then instead of #1524. No need to fix a bug the "wrong" or not good enough way. |
Maybe it's worth waiting for #1526 |
7 tasks
Gustl22
added a commit
that referenced
this issue
Oct 22, 2023
# Description - Make the position stream updates configurable via `PositionUpdater`: - By default the position stream is updated on every new frame with help of `FramePositionUpdater`. - If setting the `AudioPlayer.positionUpdater` to `TimerPositionUpdater`, the position stream is updated in the according interval. - The execution on the separate IO thread on Android was moved to the relevant code part in `SoundPoolPlayer`. ## Breaking Change - [x] Yes, this is a breaking change. - [ ] No, this is *not* a breaking change. ### Migration instructions Removed in `audioplayers_platform_interface`: ``` AudioEventType.position AudioEvent.position ``` ## Related Issues Closes #349 Closes #1525
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
bug
platform-android
Affects the android platform
waiting for report
Wait for the author to respond to the conversation
PS. This is similar to #1524, but not the same thing.
By logging, it seems that the various methods of
WrappedPlayer
are called in multiple threads. However, WrappedPlayer has several fields likeplaying
,prepared
, etc, without any protection such asvolatile
,synchronized
or anything like that. Therefore, the code seems to have bugs related to concurrency.The text was updated successfully, but these errors were encountered: