Fix kassert panic when inserting multipath routes from multiple threads.
Reported by: Marco Zec <zec at fer.hr> MFC after: immediately
This commit is contained in:
parent
57b9a062d1
commit
2476178e6b
@ -488,7 +488,9 @@ get_nhgrp(struct nh_control *ctl, struct weightened_nhop *wn, int num_nhops,
|
||||
if (link_nhgrp(ctl, key) == 0) {
|
||||
/* Unable to allocate index? */
|
||||
*perror = EAGAIN;
|
||||
destroy_nhgrp(key);
|
||||
free_nhgrp_nhops(key);
|
||||
destroy_nhgrp_int(key);
|
||||
return (NULL);
|
||||
}
|
||||
*perror = 0;
|
||||
return (key);
|
||||
|
Loading…
Reference in New Issue
Block a user