diff options
| author | Donald Sharp <sharpd@cumulusnetworks.com> | 2018-06-21 21:55:38 -0400 | 
|---|---|---|
| committer | Donald Sharp <sharpd@cumulusnetworks.com> | 2018-07-29 12:43:23 -0400 | 
| commit | 8bc8de2c155f33e1af273ed53dbf47c948a5c56e (patch) | |
| tree | 0d4d599c230efeb89853ad36f4fde04919ac3131 /staticd/static_nht.c | |
| parent | 40ecd8e46da41b5032707bd4fcbb8cc8890ded61 (diff) | |
staticd: Allow daemon to have backup static routes
Modify staticd to allow it to have backup static routes
with higher admin distance.
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
Diffstat (limited to 'staticd/static_nht.c')
| -rw-r--r-- | staticd/static_nht.c | 8 | 
1 files changed, 6 insertions, 2 deletions
diff --git a/staticd/static_nht.c b/staticd/static_nht.c index aea175b19b..f9f937f905 100644 --- a/staticd/static_nht.c +++ b/staticd/static_nht.c @@ -70,8 +70,12 @@ void static_nht_update(struct prefix *p, uint32_t nh_num,  			if (orig != si->nh_valid)  				reinstall = true; + +			if (reinstall) { +				static_zebra_route_add(rn, si, vrf_id, +						       SAFI_UNICAST, true); +				reinstall = false; +			}  		} -		if (reinstall) -			static_zebra_route_add(rn, vrf_id, SAFI_UNICAST, true);  	}  }  | 
