You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Jan 30, 2020. It is now read-only.
fleetctl: fix wrong error value from matchLocalFileAndUnit()
In matchLocalFileAndUnit(), if os.Stat() returns nil and
getUnitFromFile() returns non-nil error, then in the end
matchLocalFileAndUnit() will return (false, nil). That's not the
expected result. It should have returned the second error that came
from getUnitFromFile().
To avoid further potential bugs, let's follow the idiomatic coding
style: first check err != nil, and fail-fast.
This issue was discoverd by running go tools vet.
0 commit comments