From: Arran Cudbard-Bell Date: Wed, 15 Sep 2021 19:38:43 +0000 (-0500) Subject: No longer true X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=dad200af20011523a19ad5a8a763bdaae4d83106;p=thirdparty%2Ffreeradius-server.git No longer true --- diff --git a/src/lib/server/state.c b/src/lib/server/state.c index 86ec95507c..08830d0185 100644 --- a/src/lib/server/state.c +++ b/src/lib/server/state.c @@ -382,16 +382,7 @@ static fr_state_entry_t *state_entry_create(fr_state_tree_t *state, request_t *r if (!old) { too_many = (state->used_sessions == (uint32_t) state->max_sessions); if (!too_many) state->used_sessions++; /* preemptively increment whilst we hold the mutex */ - } - - /* - * Record the information from the old state, we may base the - * new state off the old one. - * - * Once we release the mutex, the state of old becomes indeterminate - * so we have to grab the values now. - */ - if (old) { + } else { old_tries = old->tries; memcpy(old_state, old->state, sizeof(old_state)); }