mirror of
https://github.com/matrix-org/dendrite.git
synced 2025-12-31 10:43:10 -06:00
Tidy up
This commit is contained in:
parent
59365c87c3
commit
cda580bdbe
|
|
@ -27,7 +27,6 @@ type missingStateReq struct {
|
||||||
origin gomatrixserverlib.ServerName
|
origin gomatrixserverlib.ServerName
|
||||||
db *shared.RoomUpdater
|
db *shared.RoomUpdater
|
||||||
inputer *Inputer
|
inputer *Inputer
|
||||||
roomInfo *types.RoomInfo
|
|
||||||
keys gomatrixserverlib.JSONVerifier
|
keys gomatrixserverlib.JSONVerifier
|
||||||
federation fedapi.FederationInternalAPI
|
federation fedapi.FederationInternalAPI
|
||||||
roomsMu *internal.MutexByRoom
|
roomsMu *internal.MutexByRoom
|
||||||
|
|
@ -383,10 +382,8 @@ func (t *missingStateReq) lookupStateAfterEventLocally(ctx context.Context, room
|
||||||
t.hadEvent(ev.EventID())
|
t.hadEvent(ev.EventID())
|
||||||
}
|
}
|
||||||
|
|
||||||
stateEvents = nil
|
// encourage GC
|
||||||
stateEventNIDs = nil
|
stateEvents, stateEventNIDs, stateEntries, stateAtEvents = nil, nil, nil, nil // nolint:ineffassign
|
||||||
stateEntries = nil
|
|
||||||
stateAtEvents = nil
|
|
||||||
|
|
||||||
missingAuthEvents := map[string]bool{}
|
missingAuthEvents := map[string]bool{}
|
||||||
res.AuthEvents = make([]*gomatrixserverlib.Event, 0, len(stateEvents)*3)
|
res.AuthEvents = make([]*gomatrixserverlib.Event, 0, len(stateEvents)*3)
|
||||||
|
|
@ -659,7 +656,9 @@ func (t *missingStateReq) lookupMissingStateViaStateIDs(ctx context.Context, roo
|
||||||
delete(missing, evID)
|
delete(missing, evID)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
events = nil // allow GC
|
|
||||||
|
// encourage GC
|
||||||
|
events = nil // nolint:ineffassign
|
||||||
|
|
||||||
concurrentRequests := 8
|
concurrentRequests := 8
|
||||||
missingCount := len(missing)
|
missingCount := len(missing)
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue