value is only used after checking if it's valid or not.
CID
1502921
OK stsp@ phessler@
-/* $OpenBSD: ieee80211_ra.c,v 1.1 2021/03/12 16:26:27 stsp Exp $ */
+/* $OpenBSD: ieee80211_ra.c,v 1.2 2021/03/25 16:23:39 mestre Exp $ */
/*
* Copyright (c) 2021 Christian Ehrhardt <ehrhardt@genua.de>
static const uint64_t alpha = RA_FP_1 / 8; /* 1/8 = 0.125 */
static const uint64_t beta = RA_FP_1 / 4; /* 1/4 = 0.25 */
int s, sgi20;
- struct ieee80211_ra_goodput_stats *g = &rn->g[mcs];
+ struct ieee80211_ra_goodput_stats *g;
uint64_t sfer, rate, delta;
/*
s = splnet();
+ g = &rn->g[mcs];
g->nprobe_pkts += total;
g->nprobe_fail += fail;