pkg/utils: sysctl package should use black-box testing

Signed-off-by: Bruce Ma <brucema19901024@gmail.com>
This commit is contained in:
Bruce Ma
2020-01-27 21:09:04 +08:00
parent 832f2699c2
commit 37207f05b4
2 changed files with 7 additions and 6 deletions

View File

@ -59,7 +59,7 @@ func setSysctl(name, value string) (string, error) {
// Sysctl names can use dots or slashes as separator:
// - if dots are used, dots and slashes are interchanged.
// - if slashes are used, slashes and dots are left intact.
// Separator in use is determined by firt ocurrence.
// Separator in use is determined by first occurrence.
func toNormalName(name string) string {
interchange := false
for _, c := range name {