Actually show the error occurring if a file audit log can't be opened

This commit is contained in:
Jeff Mitchell 2016-08-15 16:26:36 -04:00
parent dcba6129e3
commit 638e61192a
1 changed files with 1 additions and 1 deletions

View File

@ -57,7 +57,7 @@ func Factory(conf *audit.BackendConfig) (audit.Backend, error) {
// otherwise it will be too late to catch later without problems
// (ref: https://github.com/hashicorp/vault/issues/550)
if err := b.open(); err != nil {
return nil, fmt.Errorf("sanity check failed; unable to open %s for writing", path)
return nil, fmt.Errorf("sanity check failed; unable to open %s for writing: %v", path, err)
}
return b, nil