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

x/text: unicode/bidi/core.go:489 Defect type: UNUSED_VALUE #46230

Closed
opohorel opened this issue May 18, 2021 · 4 comments
Closed

x/text: unicode/bidi/core.go:489 Defect type: UNUSED_VALUE #46230

opohorel opened this issue May 18, 2021 · 4 comments

Comments

@opohorel
Copy link

Static analyzer has detected this issue in x/text/unicode/bidi/core.go:489.
As I'm not familiar with golang and x/text, this could be a false positive.

git-lfs-2.13.3/_build/src/github.com/git-lfs/git-lfs/vendor/golang.org/x/text/unicode/bidi/core.go:489: assigned_value: Assigning value "10" to "precedingCharacterType" here, but that stored value is overwritten before it can be used. 

   487|   		} else {
   488|   			if t.in(LRI, RLI, FSI, PDI) {
   489|-> 				precedingCharacterType = ON
   490|   			}
   491|   			precedingCharacterType = t
@gopherbot gopherbot added this to the Unreleased milestone May 18, 2021
@davecheney
Copy link
Contributor

Which tool is this?

@opohorel
Copy link
Author

Which tool is this?

Red Hat Coverity Scan that ran on git-lfs package. It detected an issue in bundled dependency x/text.
The same scan also detected #46231 in x/sync.

@davecheney
Copy link
Contributor

Please feel free to send a PR.

@bcmills
Copy link
Contributor

bcmills commented May 18, 2021

Duplicate of #43623

@bcmills bcmills marked this as a duplicate of #43623 May 18, 2021
@bcmills bcmills closed this as completed May 18, 2021
@golang golang locked and limited conversation to collaborators May 18, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

4 participants