From 1b8e202abf3a7d9faa978d6bbbc6cad122bb4fa1 Mon Sep 17 00:00:00 2001 From: guoguangwu Date: Mon, 30 Oct 2023 14:25:24 +0800 Subject: [PATCH] chore: use bytes.Equal(canaryLog, log) instead Signed-off-by: guoguangwu --- monitor.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/monitor.go b/monitor.go index ce59174..4e80206 100644 --- a/monitor.go +++ b/monitor.go @@ -179,7 +179,7 @@ func (m *_monitor) readloop( log := logbuf[0:nread] - if bytes.Compare(canaryLog, log) == 0 { + if bytes.Equal(canaryLog, log) { m.log.Debugf("received 'unexpect stream type'") continue }