Free up pdus slice so only references remaining are in channel

This commit is contained in:
Neil Alexander 2021-06-30 17:12:36 +01:00
parent 8558075e8c
commit b96f6ca3f7
No known key found for this signature in database
GPG key ID: A02A2019A2BB0944

View file

@ -260,6 +260,7 @@ func (t *txnReq) processTransaction(ctx context.Context) (*gomatrixserverlib.Res
for _, e := range pdus {
perRoom[e.RoomID()] <- e.Unwrap()
}
pdus = nil // nolint:ineffassign
var wg sync.WaitGroup
wg.Add(len(perRoom))