summaryrefslogtreecommitdiff
path: root/pceplib/pcep_utils_memory.c
diff options
context:
space:
mode:
authorSoumya Roy <souroy@nvidia.com>2025-03-14 21:56:48 +0000
committerSoumya Roy <souroy@nvidia.com>2025-03-20 16:13:44 +0000
commit6fe9092eb312e196260ee8deefb73b3f864b1432 (patch)
tree71f2f3a1cb2bef0dd9cb6909513626387fbe8234 /pceplib/pcep_utils_memory.c
parent4de0f16a89da069e8fa9920ac888ff8aed4cc6e8 (diff)
zebra: zebra crash for zapi stream
Issue: If static route is created with a BGP route as nexthop, which recursively resolves over 512 ECMP v6 nexthops, zapi nexthop encode fails, as there is not enough memory allocated for stream. This causes assert/core dump in zebra. Right now we allocate fixed memory of ZEBRA_MAX_PACKET_SIZ size. Fix: 1)Dynamically calculate required memory size for the stream 2)try to optimize memory usage Testing: No crash happens anymore with the fix zebra: zebra crash for zapi stream Issue: If static route is created with a BGP route as nexthop, which recursively resolves over 512 ECMP v6 nexthops, zapi nexthop encode fails, as there is not enough memory allocated for stream. This causes assert/core dump in zebra. Right now we allocate fixed memory of ZEBRA_MAX_PACKET_SIZ size. Fix: 1)Dynamically calculate required memory size for the stream 2)try to optimize memory usage Testing: No crash happens anymore with the fix r1# r1# sharp install routes 2100:cafe:: nexthop 2001:db8::1 1000 r1# r2# conf r2(config)# ipv6 route 2503:feca::100/128 2100:cafe::1 r2(config)# exit r2# Signed-off-by: Soumya Roy <souroy@nvidia.com>
Diffstat (limited to 'pceplib/pcep_utils_memory.c')
0 files changed, 0 insertions, 0 deletions