Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: return error if target binary is not set #339

Merged
merged 2 commits into from
Sep 21, 2023

Conversation

rogercoll
Copy link
Contributor

If OTEL_GO_AUTO_TARGET_EXE is not defined, a runtime panic is triggered:

panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x8 pc=0x96796c]

goroutine 1 [running]:
go.opentelemetry.io/auto/internal/pkg/process.(*TargetArgs).Validate(...)

If OTEL_GO_AUTO_TARGET_EXE is not defined, a runtime panic is triggered:

panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x8 pc=0x96796c]

goroutine 1 [running]:
go.opentelemetry.io/auto/internal/pkg/process.(*TargetArgs).Validate(...)
@rogercoll rogercoll requested a review from a team as a code owner September 21, 2023 13:34
instrumentation.go Outdated Show resolved Hide resolved
Co-authored-by: Przemyslaw Delewski <102958445+pdelewski@users.noreply.github.com>
@pdelewski pdelewski merged commit a070680 into open-telemetry:main Sep 21, 2023
13 checks passed
@rogercoll rogercoll deleted the fix_nil_reference branch September 21, 2023 13:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants