diff options
author | Patrick Steinhardt <ps@pks.im> | 2017-12-15 04:01:13 -0600 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-12-15 04:01:13 -0600 |
commit | c342c1313239950b0a324b229851ad0af9252da3 (patch) | |
tree | e3171caa5f6fc6ba02c82d25eadaa29731a8edca | |
parent | 1bf173c33a217a2e4766d8c144b7935010dfa7d6 (diff) | |
parent | 1b2e83a9b04726c5c7e5f9d1e77fd1abd30352ec (diff) | |
download | libgit2-c342c1313239950b0a324b229851ad0af9252da3.tar.gz |
Merge pull request #4444 from tiennou/fix/4440
stransport: provide error message on trust failures
-rw-r--r-- | src/streams/stransport.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/streams/stransport.c b/src/streams/stransport.c index 64a5dd76f..cca17bb94 100644 --- a/src/streams/stransport.c +++ b/src/streams/stransport.c @@ -83,8 +83,10 @@ static int stransport_connect(git_stream *stream) } if (sec_res == kSecTrustResultDeny || sec_res == kSecTrustResultRecoverableTrustFailure || - sec_res == kSecTrustResultFatalTrustFailure) + sec_res == kSecTrustResultFatalTrustFailure) { + giterr_set(GITERR_SSL, "untrusted connection error"); return GIT_ECERTIFICATE; + } return 0; |