<p>Friendly Automation <strong>submitted</strong> this change.</p><p><a href="https://gerrit.asterisk.org/c/asterisk/+/17906">View Change</a></p><div style="white-space:pre-wrap">Approvals:
Sean Bright: Looks good to me, but someone else must approve
George Joseph: Looks good to me, approved
Friendly Automation: Approved for Submit
</div><pre style="font-family: monospace,monospace; white-space: pre-wrap;">main/utils: Implement ast_get_tid() for NetBSD<br><br>Implement the ast_get_tid() function for NetBSD system. NetBSD supports<br>getting the TID via _lwp_self().<br><br>ASTERISK-29850<br><br>Change-Id: If57fd3f9ea15ef5d010bfbdcbbbae9b379f72f8c<br>---<br>M main/utils.c<br>1 file changed, 4 insertions(+), 0 deletions(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;"><span>diff --git a/main/utils.c b/main/utils.c</span><br><span>index dc94c99..29676fa 100644</span><br><span>--- a/main/utils.c</span><br><span>+++ b/main/utils.c</span><br><span>@@ -36,6 +36,8 @@</span><br><span> #include <unistd.h></span><br><span> #if defined(__APPLE__)</span><br><span> #include <mach/mach.h></span><br><span style="color: hsl(120, 100%, 40%);">+#elif defined(__NetBSD__)</span><br><span style="color: hsl(120, 100%, 40%);">+#include <lwp.h></span><br><span> #elif defined(HAVE_SYS_THR_H)</span><br><span> #include <sys/thr.h></span><br><span> #endif</span><br><span>@@ -2659,6 +2661,8 @@</span><br><span> long lwpid;</span><br><span> thr_self(&lwpid); /* available since sys/thr.h creation 2003 */</span><br><span> ret = lwpid;</span><br><span style="color: hsl(120, 100%, 40%);">+#elif defined(__NetBSD__)</span><br><span style="color: hsl(120, 100%, 40%);">+ ret = _lwp_self();</span><br><span> #endif</span><br><span> return ret;</span><br><span> }</span><br><span></span><br></pre><div style="white-space:pre-wrap"></div><p>To view, visit <a href="https://gerrit.asterisk.org/c/asterisk/+/17906">change 17906</a>. To unsubscribe, or for help writing mail filters, visit <a href="https://gerrit.asterisk.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.asterisk.org/c/asterisk/+/17906"/><meta itemprop="name" content="View Change"/></div></div>
<div style="display:none"> Gerrit-Project: asterisk </div>
<div style="display:none"> Gerrit-Branch: 16 </div>
<div style="display:none"> Gerrit-Change-Id: If57fd3f9ea15ef5d010bfbdcbbbae9b379f72f8c </div>
<div style="display:none"> Gerrit-Change-Number: 17906 </div>
<div style="display:none"> Gerrit-PatchSet: 2 </div>
<div style="display:none"> Gerrit-Owner: Sean Bright <sean@seanbright.com> </div>
<div style="display:none"> Gerrit-Reviewer: Friendly Automation </div>
<div style="display:none"> Gerrit-Reviewer: George Joseph <gjoseph@digium.com> </div>
<div style="display:none"> Gerrit-Reviewer: Sean Bright <sean@seanbright.com> </div>
<div style="display:none"> Gerrit-CC: Michał Górny <mgorny@NetBSD.org> </div>
<div style="display:none"> Gerrit-MessageType: merged </div>