DPDK patches and discussions
 help / color / mirror / Atom feed
* [dpdk-dev] [PATCH] app/testbbdev: fix out-of-bounds read
@ 2018-01-31 13:46 Amr Mokhtar
  2018-01-31 15:03 ` Thomas Monjalon
  0 siblings, 1 reply; 2+ messages in thread
From: Amr Mokhtar @ 2018-01-31 13:46 UTC (permalink / raw)
  To: dev; +Cc: Amr Mokhtar

Coverity issue: 257033
Fixes: f714a18885a6 ("app/testbbdev: add test application for bbdev")

Signed-off-by: Amr Mokhtar <amr.mokhtar@intel.com>
---
 app/test-bbdev/test_bbdev_vector.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/app/test-bbdev/test_bbdev_vector.c b/app/test-bbdev/test_bbdev_vector.c
index 2d0852c..addef05 100644
--- a/app/test-bbdev/test_bbdev_vector.c
+++ b/app/test-bbdev/test_bbdev_vector.c
@@ -288,7 +288,7 @@ parse_data_entry(const char *key_token, char *token,
 	struct op_data_buf *op_data;
 	unsigned int *nb_ops;
 
-	if (type > DATA_NUM_TYPES) {
+	if (type >= DATA_NUM_TYPES) {
 		printf("Unknown op type: %d!\n", type);
 		return -1;
 	}
-- 
2.7.4

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2018-01-31 15:04 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-01-31 13:46 [dpdk-dev] [PATCH] app/testbbdev: fix out-of-bounds read Amr Mokhtar
2018-01-31 15:03 ` Thomas Monjalon

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).