diff options
author | Subash Abhinov Kasiviswanathan <subashab@codeaurora.org> | 2014-07-15 20:43:54 -0600 |
---|---|---|
committer | David Keitel <dkeitel@codeaurora.org> | 2016-03-22 11:05:18 -0700 |
commit | 5b7b2ca176e0f61fdbcf8a774639e35cd8b4a83f (patch) | |
tree | 15deafeddd4ac56c4c19817d02b9d9e3899e7a68 /net/rmnet_data | |
parent | 4d6ec5cecc3517bfd834d9ec042d585deca280c1 (diff) |
net: rmnet_data: Fix potential memory corruption
Fix an out of bounds array access during virtual
net device creation
CRs-fixed: 695032
Change-Id: Ie8ae1f25122f685c22d139d1abf06acf55d46782
Signed-off-by: Subash Abhinov Kasiviswanathan <subashab@codeaurora.org>
Diffstat (limited to 'net/rmnet_data')
-rw-r--r-- | net/rmnet_data/rmnet_data_vnd.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/rmnet_data/rmnet_data_vnd.c b/net/rmnet_data/rmnet_data_vnd.c index 2e4ea07cde0d..e9843c5a4386 100644 --- a/net/rmnet_data/rmnet_data_vnd.c +++ b/net/rmnet_data/rmnet_data_vnd.c @@ -561,7 +561,7 @@ int rmnet_vnd_create_dev(int id, struct net_device **new_device, char dev_prefix[IFNAMSIZ]; int p, rc = 0; - if (id < 0 || id > RMNET_DATA_MAX_VND) { + if (id < 0 || id >= RMNET_DATA_MAX_VND) { *new_device = 0; return RMNET_CONFIG_BAD_ARGUMENTS; } |