dhcpv6-ia: fix realloc bug
authorDavid Härdeman <[email protected]>
Thu, 27 Nov 2025 10:35:09 +0000 (11:35 +0100)
committerÁlvaro Fernández Rojas <[email protected]>
Thu, 27 Nov 2025 13:09:56 +0000 (14:09 +0100)
commitd21e504b38ab4c880c43b7f1649104bb2f0d2d8b
tree1da17f5d7c9c45ee5356ff8b7cb437a13d4e4206
parentae9e22ab3fadd1ca300902d952d340a70d2e9ce5
dhcpv6-ia: fix realloc bug

Commit b9db4d7061a08bf82a25222074065cce71973d0c introduced a bug, the
"hostname" variable used for the realloc would shadow the real hostname
defined at the beginning of the function. Fix this by using a different
variable name.

Fixes: b9db4d7061a0 ("dhcpv6: handle realloc failure")
Signed-off-by: David Härdeman <[email protected]>
Link: https://github.com/openwrt/odhcpd/pull/326
Signed-off-by: Álvaro Fernández Rojas <[email protected]>
src/dhcpv6-ia.c