Prevent crash by accessing memory not owned by ospfd.
Reported by: Thomas Hilse <thomas.hilse@cert-bund.de>