Skip to content

Commit

Permalink
fixup! add support for disabling SSL revocation checks in cURL
Browse files Browse the repository at this point in the history
This maintainer thought that it was discussed that you cannot `strcmp()`
blindly without checking for NULL first, but subsequently forgot to
check that the fix had made it into the final version of the PR... :-(

The problem is that this crashes any fetch/push/clone/ls-remote
operation *unless* http.sslBackend is specified explicitly.

This probably fixes the root cause behind
#1474.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
  • Loading branch information
dscho committed Feb 5, 2018
1 parent a7e57c2 commit 60d8d6e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion http.c
Original file line number Diff line number Diff line change
Expand Up @@ -753,7 +753,8 @@ static CURL *get_curl_handle(void)
}
#endif

if (!strcmp("schannel", http_ssl_backend) && !http_schannel_check_revoke) {
if (http_ssl_backend && !strcmp("schannel", http_ssl_backend) &&
!http_schannel_check_revoke) {
#if LIBCURL_VERSION_NUM >= 0x074400
curl_easy_setopt(result, CURLOPT_SSL_OPTIONS, CURLSSLOPT_NO_REVOKE);
#else
Expand Down

0 comments on commit 60d8d6e

Please sign in to comment.