Bug 212970 - BaseAudioSharedUnit should unmute its clients in case of suspension even if not having any audio unit
Summary: BaseAudioSharedUnit should unmute its clients in case of suspension even if n...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebRTC (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: youenn fablet
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2020-06-09 06:30 PDT by youenn fablet
Modified: 2020-06-09 11:16 PDT (History)
10 users (show)

See Also:


Attachments
Patch (13.81 KB, patch)
2020-06-09 06:41 PDT, youenn fablet
no flags Details | Formatted Diff | Diff
Patch (13.81 KB, patch)
2020-06-09 08:37 PDT, youenn fablet
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description youenn fablet 2020-06-09 06:30:35 PDT
BaseAudioSharedUnit should unmute its clients in case of suspension even if not having any audio unit
Comment 1 Radar WebKit Bug Importer 2020-06-09 06:31:30 PDT
<rdar://problem/64161891>
Comment 2 youenn fablet 2020-06-09 06:41:52 PDT
Created attachment 401437 [details]
Patch
Comment 3 Eric Carlson 2020-06-09 07:15:35 PDT
Comment on attachment 401437 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=401437&action=review

> Source/WebCore/ChangeLog:9
> +        This will, in turn, make the BaseAudioSharedUnit to stop and no longer have any audio unit.

s/the BaseAudioSharedUnit to stop/the BaseAudioSharedUnit stop/

> Source/WebCore/platform/mediastream/mac/BaseAudioSharedUnit.cpp:179
> +    ASSERT(!m_producingCount);

Is this backwards?
Comment 4 youenn fablet 2020-06-09 08:36:57 PDT
Comment on attachment 401437 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=401437&action=review

>> Source/WebCore/platform/mediastream/mac/BaseAudioSharedUnit.cpp:179
>> +    ASSERT(!m_producingCount);
> 
> Is this backwards?

Given the current model, m_producingCount should be zero.
I guess I could remove the if(m_producingCount) check.
Comment 5 youenn fablet 2020-06-09 08:37:21 PDT
Created attachment 401442 [details]
Patch
Comment 6 Eric Carlson 2020-06-09 08:51:14 PDT
Comment on attachment 401442 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=401442&action=review

> Source/WebCore/platform/mediastream/mac/BaseAudioSharedUnit.cpp:180
>      if (m_producingCount) {

This is confusing given the assert.
Comment 7 youenn fablet 2020-06-09 11:03:51 PDT
(In reply to Eric Carlson from comment #6)
> Comment on attachment 401442 [details]
> Patch
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=401442&action=review
> 
> > Source/WebCore/platform/mediastream/mac/BaseAudioSharedUnit.cpp:180
> >      if (m_producingCount) {
> 
> This is confusing given the assert.

Will remove it in a follow-up
Comment 8 EWS 2020-06-09 11:16:13 PDT
Committed r262798: <https://trac.webkit.org/changeset/262798>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 401442 [details].