diff options
author | Gao Feng <gfree.wind@vip.163.com> | 2018-04-16 05:16:45 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2018-04-16 19:57:06 +0300 |
commit | 9783ccd0f2507cbe3c5ff1cb84bf6ae3a512d17d (patch) | |
tree | f84e130010e48668777e5dc15b114bf3fecc1707 /tools/perf/scripts/python/export-to-postgresql.py | |
parent | 5171b37d959641bbc619781caf62e61f7b940871 (diff) | |
download | linux-9783ccd0f2507cbe3c5ff1cb84bf6ae3a512d17d.tar.xz |
net: Fix one possible memleak in ip_setup_cork
It would allocate memory in this function when the cork->opt is NULL. But
the memory isn't freed if failed in the latter rt check, and return error
directly. It causes the memleak if its caller is ip_make_skb which also
doesn't free the cork->opt when meet a error.
Now move the rt check ahead to avoid the memleak.
Signed-off-by: Gao Feng <gfree.wind@vip.163.com>
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