From 1643637b0e13a2f1735ff6d95f24d5679b1f073c Mon Sep 17 00:00:00 2001 From: Nox <5402193+Nox-404@users.noreply.github.com> Date: Fri, 12 Jan 2024 17:12:42 +0100 Subject: [PATCH] fix(lb): removing extra frontends and backends resulted in segfault (#153) --- scaleway/loadbalancers.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scaleway/loadbalancers.go b/scaleway/loadbalancers.go index e8a3ed7..2e87590 100644 --- a/scaleway/loadbalancers.go +++ b/scaleway/loadbalancers.go @@ -1958,7 +1958,7 @@ func compareFrontends(got []*scwlb.Frontend, want map[int32]*scwlb.Frontend) fro keep[target.InboundPort] = current } } else { - remove[target.InboundPort] = current + remove[current.InboundPort] = current } } @@ -2007,7 +2007,7 @@ func compareBackends(got []*scwlb.Backend, want map[int32]*scwlb.Backend) backen keep[target.ForwardPort] = current } } else { - remove[target.ForwardPort] = current + remove[current.ForwardPort] = current } }