diff options
| author | Donald Sharp <sharpd@nvidia.com> | 2023-05-21 19:55:20 -0400 | 
|---|---|---|
| committer | Donald Sharp <sharpd@nvidia.com> | 2023-05-22 10:52:54 -0400 | 
| commit | d7c9666e060ecbd31f5fa9b384c2a56118bbb279 (patch) | |
| tree | aa81215323b7d0dc9cef85417b43bde92810e840 /zebra/zebra_dplane.c | |
| parent | b31a1797c68b1e1396ff6d8cd0738100380e43a4 (diff) | |
zebra: Fix paths that have already de-refed ctx
There is no path in some functions where the ctx
has not already been de-refed.  As such no need
to test for it's existence.
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
Diffstat (limited to 'zebra/zebra_dplane.c')
| -rw-r--r-- | zebra/zebra_dplane.c | 12 | 
1 files changed, 4 insertions, 8 deletions
diff --git a/zebra/zebra_dplane.c b/zebra/zebra_dplane.c index 3653f71527..a768c33a30 100644 --- a/zebra/zebra_dplane.c +++ b/zebra/zebra_dplane.c @@ -3799,8 +3799,7 @@ tc_qdisc_update_internal(enum dplane_op_e op,  	} else {  		atomic_fetch_add_explicit(&zdplane_info.dg_tcs_errors, 1,  					  memory_order_relaxed); -		if (ctx) -			dplane_ctx_free(&ctx); +		dplane_ctx_free(&ctx);  	}  	return result; @@ -3830,8 +3829,7 @@ tc_class_update_internal(enum dplane_op_e op, struct zebra_tc_class *class)  	} else {  		atomic_fetch_add_explicit(&zdplane_info.dg_tcs_errors, 1,  					  memory_order_relaxed); -		if (ctx) -			dplane_ctx_free(&ctx); +		dplane_ctx_free(&ctx);  	}  	return result; @@ -3861,8 +3859,7 @@ tc_filter_update_internal(enum dplane_op_e op, struct zebra_tc_filter *filter)  	} else {  		atomic_fetch_add_explicit(&zdplane_info.dg_tcs_errors, 1,  					  memory_order_relaxed); -		if (ctx) -			dplane_ctx_free(&ctx); +		dplane_ctx_free(&ctx);  	}  	return result; @@ -4230,8 +4227,7 @@ done:  	else {  		atomic_fetch_add_explicit(&zdplane_info.dg_lsp_errors, 1,  					  memory_order_relaxed); -		if (ctx) -			dplane_ctx_free(&ctx); +		dplane_ctx_free(&ctx);  	}  	return result;  }  | 
