<p>pespin <strong>uploaded patch set #2</strong> to this change.</p><p><a href="https://gerrit.osmocom.org/c/osmo-pcu/+/25044">View Change</a></p><pre style="font-family: monospace,monospace; white-space: pre-wrap;">tests/tbf: Fix null pointer access if slowly stepping with gdb<br><br>When slowly debugging test_tbf_dl_llc_loss, bssgp_tx_llc_discarded() may<br>trigger, submitting events to the libosmogb code. Since it didn't<br>properly set up the callback, it would end up in a null pointer<br>dereference when lib code tried to use backward-compatible API (which<br>was neither set up properly).<br><br>"""<br>TBF(TFI=0 TLLI=0xc0123456 DIR=DL STATE=ASSIGN) Discarding LLC PDU because lifetime limit reached, count=3 new_queue_size=0<br>BSSGP (BVCI=2234) Tx LLC-DISCARDED TLLI=0xc0123456, FRAMES=3, OCTETS=57<br>/git/libosmocore/src/gb/gprs_ns.c:271:2: runtime error: member access within null pointer of type 'struct gprs_ns_inst'<br>"""<br><br>"""<br>(gdb) bt<br> #0  0x00007ffff729cac0 in gprs_active_nsvc_by_nsei (nsi=nsi@entry=0x0, nsei=2234, bvci=bvci@entry=0)<br>    at /git/libosmocore/src/gb/gprs_ns.c:271<br> #1  0x00007ffff72b1fec in gprs_ns_sendmsg (nsi=0x0, msg=0x621000000160) at /git/libosmocore/src/gb/gprs_ns.c:1087<br> #2  0x00007ffff72d1803 in _gprs_ns_sendmsg (ctx=<optimized out>, msg=<optimized out>) at /git/libosmocore/src/gb/gprs_bssgp.c:80<br> #3  0x00007ffff730226f in bssgp_tx_llc_discarded (bctx=<optimized out>, tlli=<optimized out>, num_frames=<optimized out>, num_octets=<optimized out>)<br>    at /git/libosmocore/src/gb/gprs_bssgp_bss.c:249<br> #4  0x000055555588243e in gprs_rlcmac_dl_tbf::llc_dequeue (this=0x7ffff1622860, bctx=<optimized out>)<br>    at /git/osmo-pcu/src/tbf_dl.cpp:413<br>"""<br><br>Change-Id: Iee5bcf21afc8980a14f90f5b1ead6d2460a244ea<br>---<br>M tests/tbf/TbfTest.cpp<br>1 file changed, 41 insertions(+), 29 deletions(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">git pull ssh://gerrit.osmocom.org:29418/osmo-pcu refs/changes/44/25044/2</pre><p>To view, visit <a href="https://gerrit.osmocom.org/c/osmo-pcu/+/25044">change 25044</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/osmo-pcu/+/25044"/><meta itemprop="name" content="View Change"/></div></div>

<div style="display:none"> Gerrit-Project: osmo-pcu </div>
<div style="display:none"> Gerrit-Branch: master </div>
<div style="display:none"> Gerrit-Change-Id: Iee5bcf21afc8980a14f90f5b1ead6d2460a244ea </div>
<div style="display:none"> Gerrit-Change-Number: 25044 </div>
<div style="display:none"> Gerrit-PatchSet: 2 </div>
<div style="display:none"> Gerrit-Owner: pespin <pespin@sysmocom.de> </div>
<div style="display:none"> Gerrit-Reviewer: Jenkins Builder </div>
<div style="display:none"> Gerrit-CC: daniel <dwillmann@sysmocom.de> </div>
<div style="display:none"> Gerrit-MessageType: newpatchset </div>