diff options
author | Alex Elder <elder@linaro.org> | 2022-11-16 16:37:18 -0600 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2022-11-18 11:46:18 +0000 |
commit | 15b4f993d12b5bb81f50a1ce0693343fb7a94fcf (patch) | |
tree | 3875c6c2eb3a91bab272eb82d95d7fc3efc7238b /tools/perf/scripts/python/export-to-postgresql.py | |
parent | c609d739947894d7370eae4cf04eb2c49e910bcf (diff) |
net: ipa: avoid a null pointer dereference
Dan Carpenter reported that Smatch found an instance where a pointer
which had previously been assumed could be null (as indicated by a
null check) was later dereferenced without a similar check.
In practice this doesn't lead to a problem because currently the
pointers used are all non-null. Nevertheless this patch addresses
the reported problem.
In addition, I spotted another bug that arose in the same commit.
When the command to initialize a routing table memory region was
added, the number of entries computed for the non-hashed table
was wrong (it ended up being a Boolean rather than the count
intended). This bug is fixed here as well.
Reported-by: Dan Carpenter <error27@gmail.com>
Link: https://lore.kernel.org/kernel-janitors/Y3OOP9dXK6oEydkf@kili
Tested-by: Caleb Connolly <caleb.connolly@linaro.com>
Fixes: 5cb76899fb47 ("net: ipa: reduce arguments to ipa_table_init_add()")
Signed-off-by: Alex Elder <elder@linaro.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'tools/perf/scripts/python/export-to-postgresql.py')
0 files changed, 0 insertions, 0 deletions