You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have searched the issue tracker for open issues that relate to the same problem, before opening a new one.
This issue only relates to a single bug. I will open new issues for any other problems.
Describe the bug
We used the Fuzz engine to modify some Test(TestInMemoryRepositoryListing) data, and then the following crash appeared. We debugged and eventually found the crash point is at line 300 of internal/repository/json.go. We feel that this could be an out-of-boundary bug.
How to reproduce
The simplified test code is in Example code
Screenshots
Crash log
panic: runtime error: index out of range [-1] [recovered]
panic: runtime error: index out of range [-1]
goroutine 19 [running]:
testing.tRunner.func1.2({0x3f3d60, 0xc0000a2780})
D:/.../go1.19/src/testing/testing.go:1396 +0x24e
testing.tRunner.func1()
D:/.../go1.19/src/testing/testing.go:1399 +0x39f
panic({0x3f3d60, 0xc0000a2780})
D:/.../go1.19/src/runtime/panic.go:884 +0x212
fyne.io/fyne/v2/internal/repository.(*InMemoryRepository).List(0xc00009c258, {0x4b9518?, 0xc0000e4690?})
D:/.../fyne/internal/repository/memory.go:300 +0x32e
fyne.io/fyne/v2/storage.List({0x4b9518, 0xc0000e4690})
D:/.../fyne/storage/uri.go:479 +0x58
fyne.io/fyne/v2/internal/repository.TestInMemoryRepositoryListing2(0x0?)
D:/.../fyne/internal/repository/InMemoryRepositoryListing_fuzz_test.go:41 +0xfc
testing.tRunner(0xc000084d00, 0x44c160)
D:/.../go1.19/src/testing/testing.go:1446 +0x10b
created by testing.(*T).Run
D:/.../go1.19/src/testing/testing.go:1493 +0x35f
Checklist
Describe the bug
We used the Fuzz engine to modify some Test(TestInMemoryRepositoryListing) data, and then the following crash appeared. We debugged and eventually found the crash point is at line 300 of
internal/repository/json.go
. We feel that this could be an out-of-boundary bug.How to reproduce
The simplified test code is in Example code
Screenshots
Crash log
Example code
Fyne version
commit cfb88d7
Go compiler version
1.19
Operating system and version
Windows 10
Additional Information
No response
The text was updated successfully, but these errors were encountered: