Bug 287149
| Summary: | [GStreamer] Avoid intermediate copies in GStreamerWebRTCUtils.cpp | ||
|---|---|---|---|
| Product: | WebKit | Reporter: | Adrian Perez <aperez> |
| Component: | WebRTC | Assignee: | Adrian Perez <aperez> |
| Status: | RESOLVED FIXED | ||
| Severity: | Normal | CC: | webkit-bug-importer, youennf |
| Priority: | P2 | Keywords: | InRadar |
| Version: | Other | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| Bug Depends on: | |||
| Bug Blocks: | 266396 | ||
Adrian Perez
Functions x509Serialize() and privateKeySerialize() in Source/WebCore/Modules/mediastream/gstreamer/GStreamerWebRTCUtils.cpp use an intermedia Vector<char> as a temporary buffer to read back the values that have been serialized via BIO_write_*, then create a WTF::String that will contain a copy of the buffer contents. Instead of doing this, we can use BIO_get_mem_data() to pass the underlying buffer used by the BIO functions to create the String, and avoid one copy into the Vector<char> buffer.
| Attachments | ||
|---|---|---|
| Add attachment proposed patch, testcase, etc. |
Adrian Perez
Pull request: https://github.com/WebKit/WebKit/pull/40117
EWS
Committed 289953@main (bc904f61e313): <https://commits.webkit.org/289953@main>
Reviewed commits have been landed. Closing PR #40117 and removing active labels.
Radar WebKit Bug Importer
<rdar://problem/144324306>