From e60ff660f69ee4161ee63af3147b5a77d4139e76 Mon Sep 17 00:00:00 2001 From: Ophestra Date: Thu, 11 Dec 2025 04:22:03 +0900 Subject: internal/pipewire: treat unknown opcode as fatal Skipping events can cause local state to diverge from the server. Signed-off-by: Ophestra --- internal/pipewire/core.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'internal/pipewire/core.go') diff --git a/internal/pipewire/core.go b/internal/pipewire/core.go index d115da33..f6199c44 100644 --- a/internal/pipewire/core.go +++ b/internal/pipewire/core.go @@ -764,7 +764,7 @@ func (core *Core) consume(opcode byte, files []int, unmarshal func(v any)) error return proxy.setBoundProps(&boundProps) default: - return &UnsupportedOpcodeError{opcode, core.String()} + panic(&UnsupportedOpcodeError{opcode, core.String()}) } } @@ -831,7 +831,7 @@ func (registry *Registry) consume(opcode byte, files []int, unmarshal func(v any return nil default: - return &UnsupportedOpcodeError{opcode, registry.String()} + panic(&UnsupportedOpcodeError{opcode, registry.String()}) } } -- cgit v1.3.1