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

Incorrect conversion between integer types #5571

Open
Nanmozhi22 opened this issue May 14, 2024 · 3 comments
Open

Incorrect conversion between integer types #5571

Nanmozhi22 opened this issue May 14, 2024 · 3 comments
Labels
bug Something isn't working

Comments

@Nanmozhi22
Copy link

Nanmozhi22 commented May 14, 2024

Incorrect conversion of an unsigned 64-bit integer from to a lower bit size type uint8 without an upper bound check.

If a string is parsed into an int using strconv.Atoi, and subsequently that int is converted into another integer type of a smaller size, the result can produce unexpected values.

File Reference : samplers/probability/consistent/tracestate.go:201

@Nanmozhi22 Nanmozhi22 added the bug Something isn't working label May 14, 2024
@Nanmozhi22
Copy link
Author

I will work on this issue

@Cirilla-zmh
Copy link

@Nanmozhi22
Hello, I am currently working with the Go SDK and am very interested in this issue, as it may affect our application as well. Could you provide a more detailed description of the bug?

Thank you for your effort and assistance!

@Nanmozhi22
Copy link
Author

Hello @Cirilla-zmh

Thank you for showing Interest on this issue . Actually I have made a code changes and opened an Internal PR within our Org for review . I will open a public PR shortly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants