<p>laforge has uploaded this change for <strong>review</strong>.</p><p><a href="https://gerrit.osmocom.org/c/libosmocore/+/21820">View Change</a></p><pre style="font-family: monospace,monospace; white-space: pre-wrap;">vty: Fix left shifting out of range on signed variable<br><br>Fixes following ASan runtime errors while running vty tests:<br>command.c:730:27: runtime error: left shift of 1 by 31 places cannot be represented in type 'int'<br><br>Somehow we didn't catch this one in Ie11ff18d6fd9f6e1e91a51b6156fb6b0b7d3a9a8<br><br>Change-Id: I601caf7daa947f3cf391316f1011007ef9188c90<br>---<br>M src/vty/command.c<br>1 file changed, 1 insertion(+), 1 deletion(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/20/21820/1</pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;"><span>diff --git a/src/vty/command.c b/src/vty/command.c</span><br><span>index b38be34..4825109 100644</span><br><span>--- a/src/vty/command.c</span><br><span>+++ b/src/vty/command.c</span><br><span>@@ -727,7 +727,7 @@</span><br><span>                      char flag;</span><br><span> </span><br><span>                       /* Skip attribute if *not* set */</span><br><span style="color: hsl(0, 100%, 40%);">-                       if (~cmd->usrattr & (1 << i))</span><br><span style="color: hsl(120, 100%, 40%);">+                    if (~cmd->usrattr & ((unsigned)1 << i))</span><br><span>                                 continue;</span><br><span> </span><br><span>                        xml_att_desc = xml_escape(desc[i]);</span><br><span></span><br></pre><p>To view, visit <a href="https://gerrit.osmocom.org/c/libosmocore/+/21820">change 21820</a>. To unsubscribe, or for help writing mail filters, visit <a href="https://gerrit.osmocom.org/settings">settings</a>.</p><div itemscope itemtype="http://schema.org/EmailMessage"><div itemscope itemprop="action" itemtype="http://schema.org/ViewAction"><link itemprop="url" href="https://gerrit.osmocom.org/c/libosmocore/+/21820"/><meta itemprop="name" content="View Change"/></div></div>

<div style="display:none"> Gerrit-Project: libosmocore </div>
<div style="display:none"> Gerrit-Branch: master </div>
<div style="display:none"> Gerrit-Change-Id: I601caf7daa947f3cf391316f1011007ef9188c90 </div>
<div style="display:none"> Gerrit-Change-Number: 21820 </div>
<div style="display:none"> Gerrit-PatchSet: 1 </div>
<div style="display:none"> Gerrit-Owner: laforge <laforge@osmocom.org> </div>
<div style="display:none"> Gerrit-MessageType: newchange </div>