aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/libtle_udp/udp_ctl.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/libtle_udp/udp_ctl.c b/lib/libtle_udp/udp_ctl.c
index 618a7ef..c8580ac 100644
--- a/lib/libtle_udp/udp_ctl.c
+++ b/lib/libtle_udp/udp_ctl.c
@@ -395,11 +395,10 @@ tle_udp_del_dev(struct tle_udp_dev *dev)
uint32_t p;
struct tle_udp_ctx *ctx;
- ctx = dev->ctx;
-
if (dev == NULL || dev->ctx == NULL)
return -EINVAL;
+ ctx = dev->ctx;
p = dev - ctx->dev;
if (p >= RTE_DIM(ctx->dev) ||