[webkit-reviews] review granted: [Bug 195436] WebRTC: don't use stack buffer : [Attachment 363958] Patch
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Thu Mar 7 16:59:20 PST 2019
youenn fablet <youennf at gmail.com> has granted JF Bastien
<jfbastien at apple.com>'s request for review:
Bug 195436: WebRTC: don't use stack buffer
https://bugs.webkit.org/show_bug.cgi?id=195436
Attachment 363958: Patch
https://bugs.webkit.org/attachment.cgi?id=363958&action=review
--- Comment #11 from youenn fablet <youennf at gmail.com> ---
Comment on attachment 363958
--> https://bugs.webkit.org/attachment.cgi?id=363958
Patch
View in context: https://bugs.webkit.org/attachment.cgi?id=363958&action=review
> Source/WebCore/platform/mediastream/libwebrtc/LibWebRTCAudioModule.cpp:99
> + m_data.reset(std::make_unique<char[]>(bytesPerSample * channels *
samplesPerFrame));
Would use m_data = std::make_unique.
If we go down that road, we could also allocate m_data in
StartPlayoutOnAudioThread and delete it when exiting of
StartPlayoutOnAudioThread.
That would remove the if check and deallocate it when no longer needed.
More information about the webkit-reviews
mailing list