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

[receiver/windowseventlog] Panics due to nil pointer on resize error #17879

Closed
cpheps opened this issue Jan 20, 2023 · 2 comments · Fixed by #17880
Closed

[receiver/windowseventlog] Panics due to nil pointer on resize error #17879

cpheps opened this issue Jan 20, 2023 · 2 comments · Fixed by #17880
Labels
bug Something isn't working needs triage New item requiring triage receiver/windowseventlog

Comments

@cpheps
Copy link
Contributor

cpheps commented Jan 20, 2023

Component(s)

receiver/windowseventlog

What happened?

Description

If evtRender returns an ErrorInsufficientBuffer error it returns a nil pointer for bufferUsed rather than a pointer to bufferUsed.

If the call to evtRender returns an ErrorInsufficientBuffer error in RenderSimple it needs to read the value of the returned bufferUsed in order to resize the buffer.

Steps to Reproduce

Have a windows log message larger than the default buffer size of 16 KiB. This is rare and likely why it doesn't occur very often.

Collector version

v0.66.0

Environment information

Environment

OS: Windows Server 2022

OpenTelemetry Collector configuration

No response

Log output

No response

Additional context

A pointer to bufferUsed should be returned in the case that evtRender has an ErrorInsufficientBuffer error.

@cpheps cpheps added bug Something isn't working needs triage New item requiring triage labels Jan 20, 2023
@cpheps
Copy link
Contributor Author

cpheps commented Jan 20, 2023

I would like to be assigned to this issue.

@github-actions
Copy link
Contributor

Pinging code owners:

See Adding Labels via Comments if you do not have permissions to add labels yourself.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working needs triage New item requiring triage receiver/windowseventlog
Projects
None yet
1 participant