In function rtalloc_mpath(), do not try to release the lock if the ro_rt
pointer is NULL. Reported by: (pluknet at gmail dot com)
This commit is contained in:
parent
41a05be4ea
commit
a975973d8b
@ -269,7 +269,9 @@ rtalloc_mpath(struct route *ro, int hash)
|
||||
ro->ro_rt = rtalloc1(&ro->ro_dst, 1, 0UL);
|
||||
|
||||
/* if the route does not exist or it is not multipath, don't care */
|
||||
if (!ro->ro_rt || !rn_mpath_next((struct radix_node *)ro->ro_rt)) {
|
||||
if (ro->ro_rt == NULL)
|
||||
return;
|
||||
if (rn_mpath_next((struct radix_node *)ro->ro_rt) == NULL) {
|
||||
RT_UNLOCK(ro->ro_rt);
|
||||
return;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user