diff options
| author | Dmitry Vyukov <dvyukov@google.com> | 2022-06-20 14:05:59 +0200 |
|---|---|---|
| committer | Dmitry Vyukov <dvyukov@google.com> | 2022-06-20 14:22:01 +0200 |
| commit | b9406563d876e5550ab7e93cd0d559758b8352ca (patch) | |
| tree | f6e16bb454424fee11f885a9e340efc5a64aa2fa /sys | |
| parent | 789e5a631f90bd99d7e395c8a5675a98ffb52429 (diff) | |
prog: support int8 resources in any squashing
We've got the following panic:
--- FAIL: TestMutateRandom (7.77s)
export_test.go:37: seed=1655724857302243235
--- FAIL: TestMutateRandom/test/32_shmem (0.00s)
panic: bad size [recovered]
panic: bad size
goroutine 562 [running]:
panic({0x5ea5a0, 0x8dade8})
/usr/local/go/src/runtime/panic.go:1038 +0x215
github.com/google/syzkaller/prog.(*Target).squashResult(0xc0002a9ba0, 0xc026faa7b0, 0xc026ad1bc8)
/syzkaller/gopath/src/github.com/google/syzkaller/prog/any.go:236 +0x2d1
This happens because we try to squash resource of size 1.
While we still don't have such resources in real descriptions,
we've got one in test descriptions (added in out_overlay change).
Support int8 resources in squashing procedure.
Diffstat (limited to 'sys')
| -rw-r--r-- | sys/test/any.txt | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/sys/test/any.txt b/sys/test/any.txt index 060992c3f..5e0b0367a 100644 --- a/sys/test/any.txt +++ b/sys/test/any.txt @@ -1,10 +1,11 @@ # Copyright 2018 syzkaller project authors. All rights reserved. # Use of this source code is governed by Apache 2 LICENSE that can be found in the LICENSE file. +resource anyres8[int8] resource anyres32[int32] resource anyres64[int64] -foo$anyres(a0 ptr[out, anyres32], a1 ptr[out, anyres64]) +foo$anyres(a0 ptr[out, anyres8], a1 ptr[out, anyres32], a2 ptr[out, anyres64]) foo$any0(a ptr[in, any0]) @@ -24,6 +25,7 @@ any1 { } [packed, align[2]] anyunion0 [ + res8 anyres8 res32 anyres32 res64 anyres64 ] |
