<p>Hoernchen has uploaded this change for <strong>review</strong>.</p><p><a href="https://gerrit.osmocom.org/c/libosmocore/+/19639">View Change</a></p><pre style="font-family: monospace,monospace; white-space: pre-wrap;">vty cpu sched: do not assert if sched impossible<br><br>Shared code might be used by applications that have no vty, so sched<br>can't be initialized, do not assert and break everything in this case, a<br>warning should suffice.<br><br>Change-Id: Ic40075df8d4cf9fe8f1d711f899dae9a4b5b0928<br>---<br>M src/vty/cpu_sched_vty.c<br>1 file changed, 4 insertions(+), 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/39/19639/1</pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;"><span>diff --git a/src/vty/cpu_sched_vty.c b/src/vty/cpu_sched_vty.c</span><br><span>index 3b6067a..b962284 100644</span><br><span>--- a/src/vty/cpu_sched_vty.c</span><br><span>+++ b/src/vty/cpu_sched_vty.c</span><br><span>@@ -631,7 +631,10 @@</span><br><span>   int rc = 0;</span><br><span> </span><br><span>      /* Assert subsystem was inited and structs are preset */</span><br><span style="color: hsl(0, 100%, 40%);">-        OSMO_ASSERT(sched_vty_opts);</span><br><span style="color: hsl(120, 100%, 40%);">+  if (!sched_vty_opts) {</span><br><span style="color: hsl(120, 100%, 40%);">+                LOGP(DLGLOBAL, LOGL_FATAL, "Setting cpu-affinity mask impossible: no opts!\n");</span><br><span style="color: hsl(120, 100%, 40%);">+             return 0;</span><br><span style="color: hsl(120, 100%, 40%);">+     }</span><br><span> </span><br><span>        if (pthread_getname_np(pthread_self(), name, sizeof(name)) == 0)</span><br><span>             has_name = true;</span><br><span></span><br></pre><p>To view, visit <a href="https://gerrit.osmocom.org/c/libosmocore/+/19639">change 19639</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/+/19639"/><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: Ic40075df8d4cf9fe8f1d711f899dae9a4b5b0928 </div>
<div style="display:none"> Gerrit-Change-Number: 19639 </div>
<div style="display:none"> Gerrit-PatchSet: 1 </div>
<div style="display:none"> Gerrit-Owner: Hoernchen <ewild@sysmocom.de> </div>
<div style="display:none"> Gerrit-MessageType: newchange </div>