io/router: remove panics in clipboardQueue

Since the Process* methods on clipboardQueue are called while decoding
the ops, no need to recheck for the op type.

Signed-off-by: Pierre Curto <pierre.curto@gmail.com>
This commit is contained in:
Pierre Curto
2021-10-06 09:01:44 +02:00
committed by Elias Naur
parent e11ac9784c
commit 3c34a39d88
2 changed files with 5 additions and 13 deletions
+2 -2
View File
@@ -140,9 +140,9 @@ func (q *Router) collect() {
}
q.profHandlers[op.Tag] = struct{}{}
case opconst.TypeClipboardRead:
q.cqueue.ProcessReadClipboard(encOp.Data, encOp.Refs)
q.cqueue.ProcessReadClipboard(encOp.Refs)
case opconst.TypeClipboardWrite:
q.cqueue.ProcessWriteClipboard(encOp.Data, encOp.Refs)
q.cqueue.ProcessWriteClipboard(encOp.Refs)
}
}
}