adding comment

This commit is contained in:
Gabriel mermelstein 2024-12-13 13:27:28 +01:00
parent c1f42468f2
commit 5434d967e9
No known key found for this signature in database
GPG Key ID: 82B8134785FEAE0D

View File

@ -560,7 +560,7 @@ func unregisterNode(node *WakuNode) {
func globalEventCallback(callerRet C.int, msg *C.char, len C.size_t, userData unsafe.Pointer) {
if callerRet == C.RET_OK {
eventStr := C.GoStringN(msg, C.int(len))
node, ok := nodeRegistry[userData]
node, ok := nodeRegistry[userData] // userData contains node's ctx
if ok {
node.OnEvent(eventStr)
}