Add standard error-handling for parse failure
This commit is contained in:
parent
8b06712d21
commit
5495a7e689
|
@ -268,7 +268,7 @@ func (a *ACL) GetPolicy(args *structs.ACLPolicySpecificRequest, reply *structs.S
|
|||
rules, err := policy.Parse(out.Rules)
|
||||
|
||||
if err != nil {
|
||||
// FIXME what to do? should be impossible?
|
||||
return err
|
||||
} else {
|
||||
reply.Policy.RulesJSON = rules
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue