github-vet / github-vet/rangeloop-pointer-findings
cuu/LauncherGoDev: Menu/GameShell/10_Settings/Bluetooth/bluetooth_page.go; 28 LoC
- Dominant language
- No language data
- Stars
- 0
- Forks
- 0
- PR merge metrics
- PR metrics pending
Description
Found a possible issue in [cuu/LauncherGoDev](https://www.github.com/cuu/LauncherGoDev) at [Menu/GameShell/10_Settings/Bluetooth/bluetooth_page.go](https://github.com/cuu/LauncherGoDev/blob/33136b6b16e12d2c8255c7caa89bf87b0b6cd6d8/Menu/GameShell/10_Settings/Bluetooth/bluetooth_page.go#L630-L657)
Below is the message reported by the analyzer for this snippet of code. Beware that the analyzer only reports the first
issue it finds, so please do not limit your consideration to the contents of the below message.
> reference to v is reassigned at line 648
[Click here to see the code in its original context.](https://github.com/cuu/LauncherGoDev/blob/33136b6b16e12d2c8255c7caa89bf87b0b6cd6d8/Menu/GameShell/10_Settings/Bluetooth/bluetooth_page.go#L630-L657)
Click here to show the 28 line(s) of Go which triggered the analyzer.
```go
for i, v := range self.Devices { // v == bleapi.Device
props, err := v.GetProperties()
if err != nil {
log.Fatalf("%s: Failed to get properties: %s", v.Path, err.Error())
return
}
ni := NewNetItem()
ni.Parent = self
ni.PosX = start_x
ni.PosY = start_y + i*NetItemDefaultHeight
ni.Width = UI.Width
ni.FontObj = self.ListFontObj
ni.Path = v.Path
ni.Props = props
ni.Parent = self
ni.Device = &v
if props.Name != "" {
ni.Init(props.Name)
}else {
ni.Init(props.Address)
}
self.MyList = append(self.MyList,ni)
}
```
Leave a reaction on this issue to contribute to the project by classifying this instance as a **Bug** :-1:, **Mitigated** :+1:, or **Desirable Behavior** :rocket:
See the descriptions of the classifications [here](https://github.com/github-vet/rangeclosure-findings#how-can-i-help) for more information.
commit ID: 33136b6b16e12d2c8255c7caa89bf87b0b6cd6d8
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.