<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd">
<html lang="en">
<head>
<meta content="text/html; charset=US-ASCII" http-equiv="Content-Type">
<title>
GitLab
</title>



<style>img {
max-width: 100%; height: auto;
}
</style>
</head>
<body>
<div class="content">

<h3>
PulseAudio Marge Bot pushed to branch master
at <a href="https://gitlab.freedesktop.org/pulseaudio/pulseaudio">PulseAudio / pulseaudio</a>
</h3>
<h4>
Commits:
</h4>
<ul>
<li>
<strong><a href="https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/commit/411c087095e1cb8e9d3ef5b1c850a98b81f7fa44">411c0870</a></strong>
<div>
<span>by Igor V. Kovalenko</span>
<i>at 2021-06-01T20:34:54+03:00</i>
</div>
<pre class="commit-message" style="white-space: pre-wrap; margin: 0;">alsa-mixer: prevent double-free on decibel fixes object key

When decibel fixes object is cloned, there is only a shallow copy of `key`
string member of original object. This may lead to double-free crash reported in
pipewire tracker https://gitlab.freedesktop.org/pipewire/pipewire/-/issues/1125

Fix this by doing a deep copy of `key` string to maintain correct ownership.

Part-of: <https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/merge_requests/569>
</pre>
</li>
</ul>
<h4>1 changed file:</h4>
<ul>
<li class="file-stats">
<a href="#b62939186b90a0131e4e5a52332a49d9e9b00513">
src/modules/alsa/alsa-mixer.c
</a>
</li>
</ul>
<h4>Changes:</h4>
<li id="b62939186b90a0131e4e5a52332a49d9e9b00513">
<a href="https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/commit/411c087095e1cb8e9d3ef5b1c850a98b81f7fa44#b62939186b90a0131e4e5a52332a49d9e9b00513"><strong>src/modules/alsa/alsa-mixer.c</strong></a>
<hr>
<table class="code white" style="font-family: monospace; font-size: 90%;" bgcolor="#fff" width="100%" cellpadding="0" cellspacing="0">
<tr class="line_holder match" id="" style="line-height: 1.6;">
<td class="diff-line-num unfold js-unfold old_line" data-linenumber="3571" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">...</td>
<td class="diff-line-num unfold js-unfold new_line" data-linenumber="3571" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">...</td>
<td class="line_content match " style="padding-left: 0.5em; padding-right: 0.5em; color: rgba(0,0,0,0.3);" bgcolor="#fafafa">@@ -3571,6 +3571,7 @@ finish:</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="old_line diff-line-num" data-linenumber="3571" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
3571
</td>
<td class="new_line diff-line-num" data-linenumber="3571" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
3571
</td>
<td class="line_content" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC3571" class="line" lang="c"><span class="cm" style="color: #998; font-style: italic;">                     * object. */</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="old_line diff-line-num" data-linenumber="3572" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
3572
</td>
<td class="new_line diff-line-num" data-linenumber="3572" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
3572
</td>
<td class="line_content" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC3572" class="line" lang="c">                    <span class="n" style="color: #333;">e</span><span class="o" style="font-weight: 600;">-></span><span class="n" style="color: #333;">db_fix</span> <span class="o" style="font-weight: 600;">=</span> <span class="n" style="color: #333;">pa_xnewdup</span><span class="p">(</span><span class="n" style="color: #333;">pa_alsa_decibel_fix</span><span class="p">,</span> <span class="n" style="color: #333;">db_fix</span><span class="p">,</span> <span class="mi" style="color: #099;">1</span><span class="p">);</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="old_line diff-line-num" data-linenumber="3573" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
3573
</td>
<td class="new_line diff-line-num" data-linenumber="3573" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
3573
</td>
<td class="line_content" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC3573" class="line" lang="c">                    <span class="n" style="color: #333;">e</span><span class="o" style="font-weight: 600;">-></span><span class="n" style="color: #333;">db_fix</span><span class="o" style="font-weight: 600;">-></span><span class="n" style="color: #333;">profile_set</span> <span class="o" style="font-weight: 600;">=</span> <span class="nb" style="color: #0086b3;">NULL</span><span class="p">;</span></span>
</pre>
</td>
</tr>
<tr class="line_holder new" id="" style="line-height: 1.6;">
<td class="old_line diff-line-num new" data-linenumber="3574" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #c7f0d2; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#ddfbe6">
 
</td>
<td class="new_line diff-line-num new" data-linenumber="3574" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #c7f0d2; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#ddfbe6">
3574
</td>
<td class="line_content new" style="padding-left: 0.5em; padding-right: 0.5em;" bgcolor="#ecfdf0">
<pre style="margin: 0;">+<span id="LC3574" class="line" lang="c">                    <span class="n" style="color: #333;">e</span><span class="o" style="font-weight: 600;">-></span><span class="n" style="color: #333;">db_fix</span><span class="o" style="font-weight: 600;">-></span><span class="n" style="color: #333;">key</span> <span class="o" style="font-weight: 600;">=</span> <span class="n" style="color: #333;">pa_xstrdup</span><span class="p">(</span><span class="n" style="color: #333;">db_fix</span><span class="o" style="font-weight: 600;">-></span><span class="n" style="color: #333;">key</span><span class="p">);</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="old_line diff-line-num" data-linenumber="3574" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
3574
</td>
<td class="new_line diff-line-num" data-linenumber="3575" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
3575
</td>
<td class="line_content" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC3575" class="line" lang="c">                    <span class="n" style="color: #333;">e</span><span class="o" style="font-weight: 600;">-></span><span class="n" style="color: #333;">db_fix</span><span class="o" style="font-weight: 600;">-></span><span class="n" style="color: #333;">name</span> <span class="o" style="font-weight: 600;">=</span> <span class="n" style="color: #333;">pa_xstrdup</span><span class="p">(</span><span class="n" style="color: #333;">db_fix</span><span class="o" style="font-weight: 600;">-></span><span class="n" style="color: #333;">name</span><span class="p">);</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="old_line diff-line-num" data-linenumber="3575" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
3575
</td>
<td class="new_line diff-line-num" data-linenumber="3576" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
3576
</td>
<td class="line_content" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC3576" class="line" lang="c">                    <span class="n" style="color: #333;">e</span><span class="o" style="font-weight: 600;">-></span><span class="n" style="color: #333;">db_fix</span><span class="o" style="font-weight: 600;">-></span><span class="n" style="color: #333;">db_values</span> <span class="o" style="font-weight: 600;">=</span> <span class="n" style="color: #333;">pa_xmemdup</span><span class="p">(</span><span class="n" style="color: #333;">db_fix</span><span class="o" style="font-weight: 600;">-></span><span class="n" style="color: #333;">db_values</span><span class="p">,</span> <span class="p">(</span><span class="n" style="color: #333;">db_fix</span><span class="o" style="font-weight: 600;">-></span><span class="n" style="color: #333;">max_step</span> <span class="o" style="font-weight: 600;">-</span> <span class="n" style="color: #333;">db_fix</span><span class="o" style="font-weight: 600;">-></span><span class="n" style="color: #333;">min_step</span> <span class="o" style="font-weight: 600;">+</span> <span class="mi" style="color: #099;">1</span><span class="p">)</span> <span class="o" style="font-weight: 600;">*</span> <span class="k" style="font-weight: 600;">sizeof</span><span class="p">(</span><span class="kt" style="color: #458; font-weight: 600;">long</span><span class="p">));</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="old_line diff-line-num" data-linenumber="3576" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
3576
</td>
<td class="new_line diff-line-num" data-linenumber="3577" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
3577
</td>
<td class="line_content" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC3577" class="line" lang="c">                <span class="p">}</span></span>
</pre>
</td>
</tr>

</table>
<br>
</li>

</div>
<div class="footer" style="margin-top: 10px;">
<p style="font-size: small; color: #666;">

<br>
<a href="https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/commit/411c087095e1cb8e9d3ef5b1c850a98b81f7fa44">View it on GitLab</a>.
<br>
You're receiving this email because of your account on gitlab.freedesktop.org.
If you'd like to receive fewer emails, you can
adjust your notification settings.
<script type="application/ld+json">{"@context":"http://schema.org","@type":"EmailMessage","action":{"@type":"ViewAction","name":"View Commit","url":"https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/commit/411c087095e1cb8e9d3ef5b1c850a98b81f7fa44"}}</script>


</p>
</div>
</body>
</html>