diff options
| author | Gustavo A. R. Silva <gustavo@embeddedor.com> | 2018-04-30 07:50:40 -0500 |
|---|---|---|
| committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2018-05-03 13:55:51 -0700 |
| commit | ad109ba1378679f922f7286e7a9e50e2be778d87 (patch) | |
| tree | 4b36a640e28e5be94e3b2e44e55db4fad436958e /tools/perf/scripts/python/syscall-counts.py | |
| parent | ba36d10ed146c8f997d61a9eefc1a3319ef6a44f (diff) | |
| download | linux-ad109ba1378679f922f7286e7a9e50e2be778d87.tar.gz linux-ad109ba1378679f922f7286e7a9e50e2be778d87.zip | |
staging: wilc1000: fix infinite loop and out-of-bounds access
If i < slot_id is initially true then it will remain true. Also,
as i is being decremented it will end up accessing memory out of
bounds.
Fix this by incrementing *i* instead of decrementing it.
Addresses-Coverity-ID: 1468454 ("Infinite loop")
Fixes: faa657641081 ("staging: wilc1000: refactor scan() to free kmalloc memory on failure cases")
Signed-off-by: Gustavo A. R. Silva <gustavo@embeddedor.com>
Reviewed-by: Ajay Singh <ajay.kathat@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'tools/perf/scripts/python/syscall-counts.py')
0 files changed, 0 insertions, 0 deletions
