Skip to content
Commit 3a542826 authored by Dan Streetman's avatar Dan Streetman Committed by Zbigniew Jędrzejewski-Szmek
Browse files

test: use cap_last_cap() for max supported cap number, not capability_list_length()

This test assumes capability_list_length() is an invalid cap number,
but that isn't true if the running kernel supports more caps than we were
compiled with, which results in the test failing.

Instead use cap_last_cap() + 1.

If cap_last_cap() is 63, there are no more 'invalid' cap numbers to test with,
so the invalid cap number test part is skipped.

(cherry picked from commit ebc815cd)
(cherry picked from commit b5d7ba5f)
parent 194c72ce
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment