<p></p>
<p dir="auto"><a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/eschmidbauer/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/eschmidbauer">@eschmidbauer</a> maybe this?</p>
<pre class="notranslate"><code class="notranslate">diff --git a/src/modules/nats/nats_mod.c b/src/modules/nats/nats_mod.c
index 852d0fbbab..35e6b2612f 100644
--- a/src/modules/nats/nats_mod.c
+++ b/src/modules/nats/nats_mod.c
@@ -588,7 +588,8 @@ int nats_destroy_workers()
                                        LM_ERR("could not cleanup worker connection\n");
                                }
                        }
-                       uv_poll_stop(&pub_worker->poll);
+                       if(pub_worker->poll->type != UV_UNKNOWN_HANDLE)
+                               uv_poll_stop(&pub_worker->poll);
                        shm_free(pub_worker);
                }
        }
</code></pre>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />Reply to this email directly, <a href="https://github.com/kamailio/kamailio/issues/3253#issuecomment-1260694269">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/ABO7UZOTN26DNOV65HVP53DWAQLLVANCNFSM6AAAAAAQXGUX5E">unsubscribe</a>.<br />You are receiving this because you are subscribed to this thread.<img src="https://github.com/notifications/beacon/ABO7UZOHIXVSSNKWTNY7LTLWAQLLVA5CNFSM6AAAAAAQXGUX5GWGG33NNVSW45C7OR4XAZNMJFZXG5LFINXW23LFNZ2KUY3PNVWWK3TUL5UWJTSLESVP2.gif" height="1" width="1" alt="" /><span style="color: transparent; font-size: 0; display: none; visibility: hidden; overflow: hidden; opacity: 0; width: 0; height: 0; max-width: 0; max-height: 0; mso-hide: all">Message ID: <span><kamailio/kamailio/issues/3253/1260694269</span><span>@</span><span>github</span><span>.</span><span>com></span></span></p>
<script type="application/ld+json">[
{
"@context": "http://schema.org",
"@type": "EmailMessage",
"potentialAction": {
"@type": "ViewAction",
"target": "https://github.com/kamailio/kamailio/issues/3253#issuecomment-1260694269",
"url": "https://github.com/kamailio/kamailio/issues/3253#issuecomment-1260694269",
"name": "View Issue"
},
"description": "View this Issue on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
}
]</script>