mirror of
https://github.com/curl/curl.git
synced 2026-08-02 20:40:29 +03:00
tidy-up: miscellaneous
- drop stray duplicate empty lines in docs, scripts, test data, include, examples, tests. - drop duplicate PP parenthesis. - curl-functions.m4: move literals to the right side in if expressions, to match rest of the source code. - FAQ.md: delete language designator from an URL. - packages: apply clang-format (OS400, VMS). - scripts/schemetable.c: apply clang-format. - data320: delete duplicate empty line that doesn't change the outcome. - spacecheck: extend to check for duplicate empty lines (with exceptions.) - fix whitespace nits Closes #19936
This commit is contained in:
parent
141ce4be64
commit
fe8393d7db
116 changed files with 674 additions and 1039 deletions
|
|
@ -35,45 +35,45 @@ struct detail {
|
|||
};
|
||||
|
||||
static const struct detail scheme[] = {
|
||||
{"dict", "#ifndef CURL_DISABLE_DICT" },
|
||||
{"file", "#ifndef CURL_DISABLE_FILE" },
|
||||
{"ftp", "#ifndef CURL_DISABLE_FTP" },
|
||||
{"ftps", "#if defined(USE_SSL) && !defined(CURL_DISABLE_FTP)" },
|
||||
{"gopher", "#ifndef CURL_DISABLE_GOPHER" },
|
||||
{"gophers", "#if defined(USE_SSL) && !defined(CURL_DISABLE_GOPHER)" },
|
||||
{"http", "#ifndef CURL_DISABLE_HTTP" },
|
||||
{"https", "#if defined(USE_SSL) && !defined(CURL_DISABLE_HTTP)" },
|
||||
{"imap", "#ifndef CURL_DISABLE_IMAP" },
|
||||
{"imaps", "#if defined(USE_SSL) && !defined(CURL_DISABLE_IMAP)" },
|
||||
{"ldap", "#ifndef CURL_DISABLE_LDAP" },
|
||||
{"ldaps", "#if !defined(CURL_DISABLE_LDAP) && \\\n"
|
||||
" !defined(CURL_DISABLE_LDAPS) && \\\n"
|
||||
" ((defined(USE_OPENLDAP) && defined(USE_SSL)) || \\\n"
|
||||
" (!defined(USE_OPENLDAP) && defined(HAVE_LDAP_SSL)))" },
|
||||
{"mqtt", "#ifndef CURL_DISABLE_MQTT" },
|
||||
{"pop3", "#ifndef CURL_DISABLE_POP3" },
|
||||
{"pop3s", "#if defined(USE_SSL) && !defined(CURL_DISABLE_POP3)" },
|
||||
{"rtmp", "#ifdef USE_LIBRTMP" },
|
||||
{"rtmpt", "#ifdef USE_LIBRTMP" },
|
||||
{"rtmpe", "#ifdef USE_LIBRTMP" },
|
||||
{"rtmpte", "#ifdef USE_LIBRTMP" },
|
||||
{"rtmps", "#ifdef USE_LIBRTMP" },
|
||||
{"rtmpts", "#ifdef USE_LIBRTMP" },
|
||||
{"rtsp", "#ifndef CURL_DISABLE_RTSP" },
|
||||
{"scp", "#ifdef USE_SSH" },
|
||||
{"sftp", "#ifdef USE_SSH" },
|
||||
{"smb", "#if !defined(CURL_DISABLE_SMB) && \\\n"
|
||||
" defined(USE_CURL_NTLM_CORE) && (SIZEOF_CURL_OFF_T > 4)" },
|
||||
{"smbs", "#if defined(USE_SSL) && !defined(CURL_DISABLE_SMB) && \\\n"
|
||||
" defined(USE_CURL_NTLM_CORE) && (SIZEOF_CURL_OFF_T > 4)" },
|
||||
{"smtp", "#ifndef CURL_DISABLE_SMTP" },
|
||||
{"smtps", "#if defined(USE_SSL) && !defined(CURL_DISABLE_SMTP)" },
|
||||
{"telnet", "#ifndef CURL_DISABLE_TELNET" },
|
||||
{"tftp", "#ifndef CURL_DISABLE_TFTP" },
|
||||
{"ws",
|
||||
"#if !defined(CURL_DISABLE_WEBSOCKETS) && !defined(CURL_DISABLE_HTTP)" },
|
||||
{"wss", "#if !defined(CURL_DISABLE_WEBSOCKETS) && \\\n"
|
||||
" defined(USE_SSL) && !defined(CURL_DISABLE_HTTP)" },
|
||||
{ "dict", "#ifndef CURL_DISABLE_DICT" },
|
||||
{ "file", "#ifndef CURL_DISABLE_FILE" },
|
||||
{ "ftp", "#ifndef CURL_DISABLE_FTP" },
|
||||
{ "ftps", "#if defined(USE_SSL) && !defined(CURL_DISABLE_FTP)" },
|
||||
{ "gopher", "#ifndef CURL_DISABLE_GOPHER" },
|
||||
{ "gophers", "#if defined(USE_SSL) && !defined(CURL_DISABLE_GOPHER)" },
|
||||
{ "http", "#ifndef CURL_DISABLE_HTTP" },
|
||||
{ "https", "#if defined(USE_SSL) && !defined(CURL_DISABLE_HTTP)" },
|
||||
{ "imap", "#ifndef CURL_DISABLE_IMAP" },
|
||||
{ "imaps", "#if defined(USE_SSL) && !defined(CURL_DISABLE_IMAP)" },
|
||||
{ "ldap", "#ifndef CURL_DISABLE_LDAP" },
|
||||
{ "ldaps", "#if !defined(CURL_DISABLE_LDAP) && \\\n"
|
||||
" !defined(CURL_DISABLE_LDAPS) && \\\n"
|
||||
" ((defined(USE_OPENLDAP) && defined(USE_SSL)) || \\\n"
|
||||
" (!defined(USE_OPENLDAP) && defined(HAVE_LDAP_SSL)))" },
|
||||
{ "mqtt", "#ifndef CURL_DISABLE_MQTT" },
|
||||
{ "pop3", "#ifndef CURL_DISABLE_POP3" },
|
||||
{ "pop3s", "#if defined(USE_SSL) && !defined(CURL_DISABLE_POP3)" },
|
||||
{ "rtmp", "#ifdef USE_LIBRTMP" },
|
||||
{ "rtmpt", "#ifdef USE_LIBRTMP" },
|
||||
{ "rtmpe", "#ifdef USE_LIBRTMP" },
|
||||
{ "rtmpte", "#ifdef USE_LIBRTMP" },
|
||||
{ "rtmps", "#ifdef USE_LIBRTMP" },
|
||||
{ "rtmpts", "#ifdef USE_LIBRTMP" },
|
||||
{ "rtsp", "#ifndef CURL_DISABLE_RTSP" },
|
||||
{ "scp", "#ifdef USE_SSH" },
|
||||
{ "sftp", "#ifdef USE_SSH" },
|
||||
{ "smb", "#if !defined(CURL_DISABLE_SMB) && \\\n"
|
||||
" defined(USE_CURL_NTLM_CORE) && (SIZEOF_CURL_OFF_T > 4)" },
|
||||
{ "smbs", "#if defined(USE_SSL) && !defined(CURL_DISABLE_SMB) && \\\n"
|
||||
" defined(USE_CURL_NTLM_CORE) && (SIZEOF_CURL_OFF_T > 4)" },
|
||||
{ "smtp", "#ifndef CURL_DISABLE_SMTP" },
|
||||
{ "smtps", "#if defined(USE_SSL) && !defined(CURL_DISABLE_SMTP)" },
|
||||
{ "telnet", "#ifndef CURL_DISABLE_TELNET" },
|
||||
{ "tftp", "#ifndef CURL_DISABLE_TFTP" },
|
||||
{ "ws",
|
||||
"#if !defined(CURL_DISABLE_WEBSOCKETS) && !defined(CURL_DISABLE_HTTP)" },
|
||||
{ "wss", "#if !defined(CURL_DISABLE_WEBSOCKETS) && \\\n"
|
||||
" defined(USE_SSL) && !defined(CURL_DISABLE_HTTP)" },
|
||||
{ NULL, NULL }
|
||||
};
|
||||
|
||||
|
|
@ -108,7 +108,8 @@ static void showtable(int try, int init, int shift)
|
|||
" s++;\n"
|
||||
" l--;\n"
|
||||
" }\n"
|
||||
"*/\n", init, shift);
|
||||
"*/\n",
|
||||
init, shift);
|
||||
|
||||
printf(" static const struct Curl_handler * const protocols[%d] = {", try);
|
||||
|
||||
|
|
@ -158,10 +159,10 @@ int main(void)
|
|||
for(j = 0; j < i; j++) {
|
||||
|
||||
if(num[j] == v) {
|
||||
/*
|
||||
#if 0
|
||||
printf("NOPE: %u is a dupe (%s and %s)\n",
|
||||
v, scheme[i], scheme[j]);
|
||||
*/
|
||||
#endif
|
||||
badcombo = 1;
|
||||
break;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue