Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 3e5c2d3b authored by Jamal Hadi Salim's avatar Jamal Hadi Salim Committed by David S. Miller
Browse files

[NET_SCHED]: prio qdisc boundary condition



This fixes an out-of-boundary condition when the classified
band equals q->bands. Caught by Alexey

Signed-off-by: default avatarJamal Hadi Salim <hadi@cyberus.ca>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 6253db05
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -75,7 +75,7 @@ prio_classify(struct sk_buff *skb, struct Qdisc *sch, int *qerr)
		band = res.classid;
	}
	band = TC_H_MIN(band) - 1;
	if (band > q->bands)
	if (band >= q->bands)
		return q->queues[q->prio2band[0]];

	return q->queues[band];