From 5f306330f4ac7ea3bd41438baf69f7177f4e91f2 Mon Sep 17 00:00:00 2001 From: bin Date: Tue, 26 Oct 2021 11:58:26 +0800 Subject: [PATCH] virtcontainers: delete duplicated notify in watchHypervisor function When hypervisor check failed, the notify function is called twice. Fixes: #2901 Signed-off-by: bin --- src/runtime/virtcontainers/monitor.go | 1 - 1 file changed, 1 deletion(-) diff --git a/src/runtime/virtcontainers/monitor.go b/src/runtime/virtcontainers/monitor.go index c711f95568..0b9e5816a1 100644 --- a/src/runtime/virtcontainers/monitor.go +++ b/src/runtime/virtcontainers/monitor.go @@ -142,7 +142,6 @@ func (m *monitor) watchAgent(ctx context.Context) { func (m *monitor) watchHypervisor(ctx context.Context) error { if err := m.sandbox.hypervisor.Check(); err != nil { m.notify(ctx, errors.Wrapf(err, "failed to ping hypervisor process")) - m.notify(ctx, errors.Wrapf(err, "failed to ping Hypervisor process")) return err } return nil