Skip to content

Commit

Permalink
libcontainer/seccomp/patchbpf: fix test wrt 32-bit
Browse files Browse the repository at this point in the history
This is a temporary fix for the following issue when trying to compile for i386:

> # github.com/opencontainers/runc/libcontainer/seccomp/patchbpf [github.com/opencontainers/runc/libcontainer/seccomp/patchbpf.test]
> libcontainer/seccomp/patchbpf/enosys_linux_test.go:180:20: constant 3735928559 overflows int
> libcontainer/seccomp/patchbpf/enosys_linux_test.go:204:19: constant 3735928559 overflows int
> libcontainer/seccomp/patchbpf/enosys_linux_test.go:227:25: constant 3735928559 overflows int

Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>
  • Loading branch information
kolyshkin committed Feb 3, 2021
1 parent b8c55ac commit bd980ea
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion libcontainer/seccomp/patchbpf/enosys_linux_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ func mockSyscallPayload(t *testing.T, sysno libseccomp.ScmpSyscall, arch nativeA

// retFallthrough is returned by the mockFilter. If a the mock filter returns
// this value, it indicates "fallthrough to libseccomp-generated filter".
const retFallthrough uint32 = 0xDEADBEEF
const retFallthrough uint32 = 0xBADBEEF

// mockFilter returns a BPF VM that contains a mock filter with an -ENOSYS
// stub. If the filter returns retFallthrough, the stub filter has permitted
Expand Down

0 comments on commit bd980ea

Please sign in to comment.