-
Notifications
You must be signed in to change notification settings - Fork 260
Fixed the #108 issue. #154
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
Conversation
| osInfoArr := make(map[string]string) | ||
|
|
||
| for i := range linesArr { | ||
| s := strings.Split(linesArr[i], "=") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can we check if split succeeds by checking the length of s?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please check if the latest commit is what you want.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please address the comment that I added
telemetry/telemetry_linux.go
Outdated
|
|
||
| for i := range linesArr { | ||
| s := strings.Split(linesArr[i], "=") | ||
| if len(s) = 2 { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
shouldn't it be len(s)==2?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, sorry!
IvanovOleg
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed the typo
telemetry/telemetry_linux.go
Outdated
|
|
||
| for i := range linesArr { | ||
| s := strings.Split(linesArr[i], "=") | ||
| if len(s) = 2 { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, sorry!
What this PR does / why we need it:
Use /etc/os-release instead of /etc/issue as a source for the osInfo because /etc/issue contains completely different lines depending on the linux distributive and fails on the CoreOS.
Which issue this PR fixes (optional, in
fixes #<issue number>(, fixes #<issue_number>, ...)format, will close that issue when PR gets merged): fixes #108Special notes for your reviewer:
Split PRs as required
Release note: