Skip to content

arduino-fwuploader panics #150

Closed
Closed
@umbynos

Description

@umbynos

Describe the problem

./arduino-fwuploader
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x18 pc=0x824766]

goroutine 1 [running]:
debug/elf.(*Section).ReadAt(0xc000200000?, {0xc000210000?, 0x270?, 0x24?}, 0x40?)
	<autogenerated>:1 +0x26
archive/zip.readDirectoryEnd({0xa23b20, 0xc000138e80}, 0x210)
	/opt/hostedtoolcache/go/1.19.1/x64/src/archive/zip/reader.go:526 +0xf5
archive/zip.(*Reader).init(0xc000179a40, {0xa23b20?, 0xc000138e80}, 0x210)
	/opt/hostedtoolcache/go/1.19.1/x64/src/archive/zip/reader.go:97 +0x5c
archive/zip.NewReader({0xa23b20, 0xc000138e80}, 0x210)
	/opt/hostedtoolcache/go/1.19.1/x64/src/archive/zip/reader.go:90 +0x5e
github.com/daaku/go%2ezipexe.zipExeReaderElf({0xa246c0?, 0xc0000ae0c0}, 0xd758be)
	/home/runner/go/pkg/mod/github.com/daaku/[email protected]/zipexe.go:128 +0x8b
github.com/daaku/go%2ezipexe.NewReader({0xa246c0, 0xc0000ae0c0}, 0x0?)
	/home/runner/go/pkg/mod/github.com/daaku/[email protected]/zipexe.go:48 +0x98
github.com/daaku/go%2ezipexe.OpenCloser({0xc0000d62d0?, 0xc000115720?})
	/home/runner/go/pkg/mod/github.com/daaku/[email protected]/zipexe.go:30 +0x57
github.com/cmaglie/go%2erice.init.0()
	/home/runner/go/pkg/mod/github.com/cmaglie/[email protected]/appended.go:42 +0x65

To reproduce

This seems to only affect linux 2.2.1 released binary

Expected behavior

The binary should not crash

Arduino Firmware Uploader version

arduino-fwuploader Version: 2.2.1 Commit: 75bcf76

Operating system

Linux

Operating system version

Ubuntu 18.04 (same also on archlinux)

Additional context

No response

Issue checklist

  • I searched for previous reports in the issue tracker
  • I verified the problem still occurs when using the latest version
  • My report contains all necessary details

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions