error strings should not be capitalized or end with punctuation
Signed-off-by: yupeng <yu.peng36@zte.com.cn>
This commit is contained in:
parent
e350d44dbe
commit
fc11efa2db
3 changed files with 3 additions and 3 deletions
|
@ -89,7 +89,7 @@ func ReadMemInfo() (*MemInfo, error) {
|
|||
|
||||
if ppKernel < 0 || MemTotal < 0 || MemFree < 0 || SwapTotal < 0 ||
|
||||
SwapFree < 0 {
|
||||
return nil, fmt.Errorf("Error getting system memory info %v\n", err)
|
||||
return nil, fmt.Errorf("error getting system memory info %v\n", err)
|
||||
}
|
||||
|
||||
meminfo := &MemInfo{}
|
||||
|
|
|
@ -97,7 +97,7 @@ func (ar *ansiReader) Read(p []byte) (int, error) {
|
|||
|
||||
copiedLength := copy(p, keyBytes)
|
||||
if copiedLength != len(keyBytes) {
|
||||
return 0, errors.New("Unexpected copy length encountered.")
|
||||
return 0, errors.New("unexpected copy length encountered")
|
||||
}
|
||||
|
||||
logger.Debugf("Read p[%d]: % x", copiedLength, p)
|
||||
|
|
|
@ -753,7 +753,7 @@ func parseStorageOpts(storageOpts []string) (map[string]string, error) {
|
|||
opt := strings.SplitN(option, "=", 2)
|
||||
m[opt[0]] = opt[1]
|
||||
} else {
|
||||
return nil, fmt.Errorf("Invalid storage option.")
|
||||
return nil, fmt.Errorf("invalid storage option")
|
||||
}
|
||||
}
|
||||
return m, nil
|
||||
|
|
Loading…
Reference in a new issue