MCPcopy Index your code
hub / github.com/git/git / get_curl_allowed_protocols

Function get_curl_allowed_protocols

http.c:1073–1095  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1071}
1072
1073static long get_curl_allowed_protocols(int from_user, struct strbuf *list)
1074{
1075 long bits = 0;
1076
1077 if (is_transport_allowed("http", from_user)) {
1078 bits |= CURLPROTO_HTTP;
1079 proto_list_append(list, "http");
1080 }
1081 if (is_transport_allowed("https", from_user)) {
1082 bits |= CURLPROTO_HTTPS;
1083 proto_list_append(list, "https");
1084 }
1085 if (is_transport_allowed("ftp", from_user)) {
1086 bits |= CURLPROTO_FTP;
1087 proto_list_append(list, "ftp");
1088 }
1089 if (is_transport_allowed("ftps", from_user)) {
1090 bits |= CURLPROTO_FTPS;
1091 proto_list_append(list, "ftps");
1092 }
1093
1094 return bits;
1095}
1096
1097static int get_curl_http_version_opt(const char *version_string, long *opt)
1098{

Callers 1

get_curl_handleFunction · 0.85

Calls 2

is_transport_allowedFunction · 0.85
proto_list_appendFunction · 0.85

Tested by

no test coverage detected