Skip to content

Commit 2bb1b3b

Browse files
authored
Merge pull request #6268 from oasisprotocol/kostko/fix/rofl-handler-notify-reg-nil
go/runtime: Fix nil pointer dereference in HostRegisterNotify handler
2 parents 25d02b5 + bf911d7 commit 2bb1b3b

2 files changed

Lines changed: 3 additions & 1 deletion

File tree

.changelog/6268.trivial.md

Whitespace-only changes.

go/runtime/registry/handler_rofl.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -260,7 +260,9 @@ func (rh *roflHostHandler) handleHostRegisterNotify(
260260
// Subscribe to event notifications.
261261
nfs := &rofl.Notifications{
262262
Blocks: rq.RuntimeBlock,
263-
Events: rq.RuntimeEvent.Tags,
263+
}
264+
if rq.RuntimeEvent != nil {
265+
nfs.Events = rq.RuntimeEvent.Tags
264266
}
265267
rh.roflNotifier.register(rh.id, nfs)
266268

0 commit comments

Comments
 (0)