diff options
| author | Liang Luo <luoliang@kylinos.cn> | 2026-08-07 09:39:12 +0800 |
|---|---|---|
| committer | Tejun Heo <tj@kernel.org> | 2026-08-10 09:39:35 -1000 |
| commit | 4dc310b41aba43e9d8dfafe46dce86f8b55c0354 (patch) | |
| tree | c5cbb2d8117bc77fd4e57ffcc2ad095aba42345f /tools/perf/scripts/python/stackcollapse.py | |
| parent | e158e309cd90249a90cc84e6d29e46a3d5551b7b (diff) | |
selftests/sched_ext: Check skeleton open failure in exit test
exit.c does not check the return value of exit__open(). If it returns
NULL, which happens when the skeleton wrapper fails to allocate the
object or open the BPF ELF, the very next line dereferences it via
SCX_ENUM_INIT(). That macro expands to SCX_ENUM_SET(), which accesses
skel->rodata, causing a NULL pointer dereference.
Every other selftest guards this with SCX_FAIL_IF(!skel, ...); exit.c
is the only one missing it.
Fixes: a5db7817af78 ("sched_ext: Add selftests")
Signed-off-by: Liang Luo <luoliang@kylinos.cn>
Signed-off-by: Tejun Heo <tj@kernel.org>
Diffstat (limited to 'tools/perf/scripts/python/stackcollapse.py')
0 files changed, 0 insertions, 0 deletions
