Skip to content

Commit

Permalink
config: generate more helpful errors
Browse files Browse the repository at this point in the history
  • Loading branch information
reynir committed Jun 25, 2024
1 parent 8d734e1 commit 2306665
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/config.ml
Original file line number Diff line number Diff line change
Expand Up @@ -1091,13 +1091,14 @@ let a_multi_fingerprint =
>>| fun fps -> B (Peer_fingerprint, fps)

let a_peer_fingerprint =
string "peer-fingerprint" *> a_whitespace
string "peer-fingerprint" *> a_whitespace *> commit
*> choice
[
string "[inline]" *> return (`Need_inline `Peer_fingerprint);
( choice [ a_fingerprint; fail "Bad fingerprint" ] >>| fun fp ->
( a_fingerprint <?> "fingerprint" >>| fun fp ->
`Entry (B (Peer_fingerprint, [ fp ])) );
]
~failure_msg:"bad fingerprint"

let a_key_direction_option =
choice
Expand Down

0 comments on commit 2306665

Please sign in to comment.