]> git.puffer.fish Git - mirror/frr.git/commit
babeld: Check that bodylen is within some bounds of usable
authorDonald Sharp <sharpd@nvidia.com>
Thu, 12 May 2022 17:23:36 +0000 (13:23 -0400)
committerDonald Sharp <sharpd@nvidia.com>
Thu, 12 May 2022 17:23:36 +0000 (13:23 -0400)
commit8128153ba40b3ee53dfa4a1f4c252635e6908596
treeca2cabb479db9343dfa5b13799e6f904b52d3ebf
parent601db492b8465f6ff37efcf9113be381db744182
babeld: Check that bodylen is within some bounds of usable

Coverity believed that the bodylen value was read directly
from the incoming packet and then used as a loop variable.
Unfortunately it missed the fact that in babel_packet_examin
the bodylen was actually checked to ensure that it was long
enough.  So instead of checking it 2 times, generate it one
time and let coverity figure it out from that.

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
babeld/message.c