<p>Thank you <a href="https://github.com/miconda" class="user-mention">@miconda</a> , unfortunately there is bug that I couldnt catch.</p>
<p>6 days ago I have implemented same way in my repository:</p>
<p><a href="https://github.com/adubovikov/kamailio/commit/ae15a717e9a5849b4ac295c5864cd6e9b198b6d1" class="commit-link">adubovikov/kamailio@<tt>ae15a71</tt></a></p>
<p>but your and my patches makes same results:</p>
<p>/usr/sbin/kamailio[1260]: ERROR: sl [sl_funcs.c:362]: sl_reply_error(): stateless error reply used: I'm terribly sorry, server error occurred (6/SL)<br>
this is after execution of event route. I have tested/removed some code and found that this happens once you call " fmsg = faked_msg_next();"</p>
<p>also in your patch:</p>
<p><a href="https://github.com/kamailio/kamailio/commit/f7d1d234a42198fc10e40c33e92cff5e8fc1af8e#diff-81d708cd01d1642b044346221062c4dbR522" class="commit-link"><tt>f7d1d23</tt>#diff-81d708cd01d1642b044346221062c4dbR522</a></p>
<p>should be:<br>
if(_th_eventrt_outgoing<0 <strong>&&</strong> keng==NULL) {</p>
<p>any suggestions got to avoid this SL error ?</p>
<p>Wbr,<br>
Alexandr</p>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />You are receiving this because you are subscribed to this thread.<br />Reply to this email directly, <a href="https://github.com/kamailio/kamailio/pull/1150#issuecomment-309368057">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/AF36ZT1vgiSTFzSMv2_u3PmrC-Jhwpaaks5sFiu4gaJpZM4N1SAU">mute the thread</a>.<img alt="" height="1" src="https://github.com/notifications/beacon/AF36ZSYeadTK7AfulIQoEjBxPzFdZlWQks5sFiu4gaJpZM4N1SAU.gif" width="1" /></p>
<div itemscope itemtype="http://schema.org/EmailMessage">
<div itemprop="action" itemscope itemtype="http://schema.org/ViewAction">
  <link itemprop="url" href="https://github.com/kamailio/kamailio/pull/1150#issuecomment-309368057"></link>
  <meta itemprop="name" content="View Pull Request"></meta>
</div>
<meta itemprop="description" content="View this Pull Request on GitHub"></meta>
</div>

<script type="application/json" data-scope="inboxmarkup">{"api_version":"1.0","publisher":{"api_key":"05dde50f1d1a384dd78767c55493e4bb","name":"GitHub"},"entity":{"external_key":"github/kamailio/kamailio","title":"kamailio/kamailio","subtitle":"GitHub repository","main_image_url":"https://cloud.githubusercontent.com/assets/143418/17495839/a5054eac-5d88-11e6-95fc-7290892c7bb5.png","avatar_image_url":"https://cloud.githubusercontent.com/assets/143418/15842166/7c72db34-2c0b-11e6-9aed-b52498112777.png","action":{"name":"Open in GitHub","url":"https://github.com/kamailio/kamailio"}},"updates":{"snippets":[{"icon":"PERSON","message":"@adubovikov in #1150: Thank you @miconda , unfortunately there is bug that I couldnt catch.\r\n\r\n6 days ago I have implemented same way in my repository:\r\n\r\nhttps://github.com/adubovikov/kamailio/commit/ae15a717e9a5849b4ac295c5864cd6e9b198b6d1\r\n\r\nbut your and my patches makes same results:\r\n\r\n/usr/sbin/kamailio[1260]: ERROR: sl [sl_funcs.c:362]: sl_reply_error(): stateless error reply used: I'm terribly sorry, server error occurred (6/SL)\r\nthis is after execution of event route. I have tested/removed some code and found that this happens once you call \" fmsg = faked_msg_next();\"\r\n\r\nalso in your patch:\r\n\r\nhttps://github.com/kamailio/kamailio/commit/f7d1d234a42198fc10e40c33e92cff5e8fc1af8e#diff-81d708cd01d1642b044346221062c4dbR522\r\n\r\nshould be:\r\nif(_th_eventrt_outgoing\u003c0 **\u0026\u0026** keng==NULL) {\r\n\r\nany suggestions got to avoid this SL error ?\r\n\r\nWbr,\r\nAlexandr\r\n\r\n\r\n\r\n\r\n\r\n"}],"action":{"name":"View Pull Request","url":"https://github.com/kamailio/kamailio/pull/1150#issuecomment-309368057"}}}</script>