github-vet / github-vet/rangeloop-pointer-findings
canonical/kubernetes-dqlite: staging/src/k8s.io/legacy-cloud-providers/azure/azure_storageaccount.go; 8 LoC
- Dominant language
- No language data
- Stars
- 0
- Forks
- 0
- PR merge metrics
- PR metrics pending
Description
Found a possible issue in [canonical/kubernetes-dqlite](https://www.github.com/canonical/kubernetes-dqlite) at [staging/src/k8s.io/legacy-cloud-providers/azure/azure_storageaccount.go](https://github.com/canonical/kubernetes-dqlite/blob/88d4aeadf8ccb0cf95c48c59985bc721e0e14d22/staging/src/k8s.io/legacy-cloud-providers/azure/azure_storageaccount.go#L149-L156)
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 subnetID was used in a composite literal at line 151
[Click here to see the code in its original context.](https://github.com/canonical/kubernetes-dqlite/blob/88d4aeadf8ccb0cf95c48c59985bc721e0e14d22/staging/src/k8s.io/legacy-cloud-providers/azure/azure_storageaccount.go#L149-L156)
Click here to show the 8 line(s) of Go which triggered the analyzer.
```go
for _, subnetID := range accountOptions.VirtualNetworkResourceIDs {
vnetRule := storage.VirtualNetworkRule{
VirtualNetworkResourceID: &subnetID,
Action: storage.Allow,
}
virtualNetworkRules = append(virtualNetworkRules, vnetRule)
klog.V(4).Infof("subnetID(%s) has been set", subnetID)
}
```
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: 88d4aeadf8ccb0cf95c48c59985bc721e0e14d22
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.