这是indexloc提供的服务,不要输入任何密码
Skip to content
This repository was archived by the owner on Feb 13, 2025. It is now read-only.

Conversation

@d10v
Copy link
Contributor

@d10v d10v commented Aug 4, 2016

Rarely there are /dev/md* files but no mdadm installed.

// Maybe we should use it sometime in the future
output, err := util.Command(tmout, nil, "mdadm", "--detail", volumeName)
detail := parseExamineMdadm(output)
detail := volumeDetail{}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just a minor thing. I'm much more used to seeing if err != nil blocks. How about:

if err != nil{
   return volumeDetail{}, err
}
return parseExamineMdadm(output), nil

@d10v
Copy link
Contributor Author

d10v commented Aug 5, 2016

Thank you for a quick answer, Craig.
Yeah, your suggestion is way prettier.

@captncraig captncraig merged commit fa86001 into bosun-monitor:master Aug 5, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants