summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/stackcollapse.py
diff options
context:
space:
mode:
authorJia-Ju Bai <baijiaju@buaa.edu.cn>2023-03-21 21:22:11 +0800
committerKonstantin Komarov <almaz.alexandrovich@paragon-software.com>2023-07-03 00:21:23 +0400
commit97498cd610c0d030a7bd49a7efad974790661162 (patch)
tree2dcbb6f015fccd76a495707baec7c3eefc78fd85 /tools/perf/scripts/python/stackcollapse.py
parentc9db0ff04649aa0b45f497183c957fe260f229f6 (diff)
fs: ntfs3: Fix possible null-pointer dereferences in mi_read()
In a previous commit 2681631c2973 ("fs/ntfs3: Add null pointer check to attr_load_runs_vcn"), ni can be NULL in attr_load_runs_vcn(), and thus it should be checked before being used. However, in the call stack of this commit, mft_ni in mi_read() is aliased with ni in attr_load_runs_vcn(), and it is also used in mi_read() at two places: mi_read() rw_lock = &mft_ni->file.run_lock -> No check attr_load_runs_vcn(mft_ni, ...) ni (namely mft_ni) is checked in the previous commit attr_load_runs_vcn(..., &mft_ni->file.run) -> No check Thus, to avoid possible null-pointer dereferences, the related checks should be added. These bugs are reported by a static analysis tool implemented by myself, and they are found by extending a known bug fixed in the previous commit. Thus, they could be theoretical bugs. Signed-off-by: Jia-Ju Bai <baijiaju@buaa.edu.cn> Signed-off-by: Konstantin Komarov <almaz.alexandrovich@paragon-software.com>
Diffstat (limited to 'tools/perf/scripts/python/stackcollapse.py')
0 files changed, 0 insertions, 0 deletions