Skip to content

Commit 5f03cdf

Browse files
committed
test: fix APILevelIsSupported
Functions seccomp_api_get(3) and seccomp_api_set(3) appeared in libseccomp 2.4.0, not 2.3.3 like the code assumed. This fixes TestGetAPILevel failure with libseccomp 2.3.3. Signed-off-by: Kir Kolyshkin <[email protected]>
1 parent 89225e5 commit 5f03cdf

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

seccomp_test.go

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,8 +46,7 @@ func execInSubprocess(t *testing.T, f func(t *testing.T)) {
4646

4747
func APILevelIsSupported() bool {
4848
return verMajor > 2 ||
49-
(verMajor == 2 && verMinor > 3) ||
50-
(verMajor == 2 && verMinor == 3 && verMicro >= 3)
49+
(verMajor == 2 && verMinor >= 4)
5150
}
5251

5352
func TestGetAPILevel(t *testing.T) {

0 commit comments

Comments
 (0)