Code Review
/
tldk.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
review
|
tree
raw
|
patch
| inline |
side by side
(parent:
300fdaf
)
libtle_udp: fix possible dereference of NULL ptr in tle_udp_del_dev()
13/3313/1
author
Konstantin Ananyev
<
[email protected]
>
Fri, 7 Oct 2016 10:58:00 +0000
(11:58 +0100)
committer
Konstantin Ananyev
<
[email protected]
>
Fri, 7 Oct 2016 12:57:55 +0000
(13:57 +0100)
Change-Id: I09661a97206e8714c05f4c4f31d23d250cd0933a
Signed-off-by: Konstantin Ananyev <
[email protected]
>
lib/libtle_udp/udp_ctl.c
patch
|
blob
|
history
diff --git
a/lib/libtle_udp/udp_ctl.c
b/lib/libtle_udp/udp_ctl.c
index
618a7ef
..
c8580ac
100644
(file)
--- 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) ||