Skip to content

Commit

Permalink
Merge pull request FRRouting#7603 from donaldsharp/ospf_crash_fix
Browse files Browse the repository at this point in the history
ospfd: Prevent crash by accessing memory not owned.
  • Loading branch information
ton31337 authored Nov 26, 2020
2 parents 3200009 + cf0f13d commit 4cfb2ae
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion ospfd/ospf_routemap.c
Original file line number Diff line number Diff line change
Expand Up @@ -416,7 +416,7 @@ static void *route_set_metric_compile(const char *arg)
{
struct ospf_metric *metric;

metric = XCALLOC(MTYPE_ROUTE_MAP_COMPILED, sizeof(uint32_t));
metric = XCALLOC(MTYPE_ROUTE_MAP_COMPILED, sizeof(*metric));
metric->used = false;

if (all_digit(arg))
Expand Down

0 comments on commit 4cfb2ae

Please sign in to comment.