test-dhcp6-client: add one more assert on memory mapping
authorLuca Boccassi <luca.boccassi@microsoft.com>
Thu, 25 Mar 2021 11:47:13 +0000 (11:47 +0000)
committerLuca Boccassi <luca.boccassi@microsoft.com>
Thu, 25 Mar 2021 12:02:43 +0000 (12:02 +0000)
commit7489d0640a4864d4b47fd8fda77f8eb7cf2e3fe8
tree132d50da6351559a59dec0452a8904d7fc96a2cc
parentc0ef415862b43a30590877c9f4dd16fced88fd83
test-dhcp6-client: add one more assert on memory mapping

Static analyzers need a hint that optval is not pointing
off the end of the msg_advertise array, since pos can go
up to the full length of it. The array is manually
constructed so we know this won't happen, but adding one
more assert should be enough to avoid false positives.

Coverity CID #1394277
src/libsystemd-network/test-dhcp6-client.c