diff options
| author | Joseph Richey <joerichey@google.com> | 2018-02-12 00:06:37 -0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2018-02-12 00:06:37 -0800 |
| commit | 57c646808e5f5077e60d004661bba4604650012b (patch) | |
| tree | 1ae1ed02acba2c9beef4a81652d5594c67cf60e6 /metadata | |
| parent | 3d99996924f2ee24581e8e557f3aa05ed7822e99 (diff) | |
| parent | 69630f37fcebe894b15872148bd8b2496806b60c (diff) | |
Merge pull request #87 from google/cleanup
Minor fixes and cleanup
Diffstat (limited to 'metadata')
| -rw-r--r-- | metadata/policy.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/metadata/policy.go b/metadata/policy.go index 533d48a..ce40f9c 100644 --- a/metadata/policy.go +++ b/metadata/policy.go @@ -86,7 +86,7 @@ func GetPolicy(path string) (*PolicyData, error) { defer file.Close() var policy unix.FscryptPolicy - if err := policyIoctl(file, unix.FS_IOC_GET_ENCRYPTION_POLICY, &policy); err != nil { + if err = policyIoctl(file, unix.FS_IOC_GET_ENCRYPTION_POLICY, &policy); err != nil { return nil, errors.Wrapf(err, "get encryption policy %s", path) } @@ -119,7 +119,7 @@ func SetPolicy(path string, data *PolicyData) error { } defer file.Close() - if err := data.CheckValidity(); err != nil { + if err = data.CheckValidity(); err != nil { return errors.Wrap(err, "invalid policy") } |