]> git.ipfire.org Git - thirdparty/git.git/commit
netrc: ignore unknown lines (do not die)
authorMatthew John Cheetham <mjcheetham@outlook.com>
Thu, 22 Sep 2022 16:59:33 +0000 (16:59 +0000)
committerJunio C Hamano <gitster@pobox.com>
Thu, 22 Sep 2022 21:20:59 +0000 (14:20 -0700)
commit6ea87d97af30c25ce48b524943ec9493bd5e51ca
tree2ac9d8f278756de524368d63a6111775a88a31f4
parentd69580498370236a93014e1b1b57685d1709b6c8
netrc: ignore unknown lines (do not die)

Contrary to the documentation on credential helpers, as well as the help
text for git-credential-netrc itself, this helper will `die` when
presented with an unknown property/attribute/token.

Correct the behaviour here by skipping and ignoring any tokens that are
unknown. This means all helpers in the tree are consistent and ignore
any unknown credential properties/attributes.

Signed-off-by: Matthew John Cheetham <mjcheetham@outlook.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
contrib/credential/netrc/git-credential-netrc.perl