From: Eugene Syromiatnikov Date: Sun, 3 Aug 2025 22:55:59 +0000 (+0200) Subject: Eliminate indentation tabs from *.c and *.h files X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=eea6315408827ed5b490935022b314973383950e;p=thirdparty%2Fopenssl.git Eliminate indentation tabs from *.c and *.h files While the majority of the sites assumed 8-wide tabs, at least engines/e_capi.c assumed 4-wide; in any case it is better to just follow the code style guide and eliminate them altogether. Some addition changes (namely, curly brackets in apps/crl.c and apps/req.c, and additional whitespace changes in apps/s_client.c and test/provider_pkey_test.c) are made to placate check-format-commit.sh. Signed-off-by: Eugene Syromiatnikov Reviewed-by: Neil Horman Reviewed-by: Paul Dale (Merged from https://github.com/openssl/openssl/pull/28162) --- diff --git a/apps/crl.c b/apps/crl.c index afb59178fda..670308a4f8c 100644 --- a/apps/crl.c +++ b/apps/crl.c @@ -250,9 +250,10 @@ int crl_main(int argc, char **argv) goto end; if (i == 0) { BIO_printf(bio_err, "verify failure\n"); - goto end; - } else + goto end; + } else { BIO_printf(bio_err, "verify OK\n"); + } } if (crldiff != NULL) { diff --git a/apps/req.c b/apps/req.c index 7398b862ab1..1691175a271 100644 --- a/apps/req.c +++ b/apps/req.c @@ -944,9 +944,10 @@ int req_main(int argc, char **argv) goto end; if (i == 0) { BIO_printf(bio_err, "Certificate request self-signature verify failure\n"); - goto end; - } else /* i > 0 */ + goto end; + } else /* i > 0 */ { BIO_printf(bio_out, "Certificate request self-signature verify OK\n"); + } } if (noout && !text && !modulus && !subject && !pubkey) { diff --git a/apps/s_client.c b/apps/s_client.c index b5c4ccffd3b..836c6b81222 100644 --- a/apps/s_client.c +++ b/apps/s_client.c @@ -1665,7 +1665,7 @@ int s_client_main(int argc, char **argv) } if (proxystr != NULL) { -#ifndef OPENSSL_NO_HTTP +# ifndef OPENSSL_NO_HTTP int res; char *tmp_host = host, *tmp_port = port; @@ -1700,11 +1700,11 @@ int s_client_main(int argc, char **argv) "%s: -proxy argument malformed or ambiguous\n", prog); goto end; } -#else +# else BIO_printf(bio_err, "%s: -proxy not supported in no-http build\n", prog); - goto end; -#endif + goto end; +# endif } diff --git a/crypto/loongarchcap.c b/crypto/loongarchcap.c index 2123fd9c083..9772a980903 100644 --- a/crypto/loongarchcap.c +++ b/crypto/loongarchcap.c @@ -13,5 +13,5 @@ unsigned int OPENSSL_loongarch_hwcap_P = 0; void OPENSSL_cpuid_setup(void) { - OPENSSL_loongarch_hwcap_P = getauxval(AT_HWCAP); + OPENSSL_loongarch_hwcap_P = getauxval(AT_HWCAP); } diff --git a/engines/e_capi.c b/engines/e_capi.c index 3c15158b8aa..73a81f7d168 100644 --- a/engines/e_capi.c +++ b/engines/e_capi.c @@ -1144,8 +1144,8 @@ static char *wide_to_asc(LPCWSTR wstr) len_1 = wcslen(wstr) + 1; if (len_1 > INT_MAX) { - CAPIerr(CAPI_F_WIDE_TO_ASC, CAPI_R_FUNCTION_NOT_SUPPORTED); - return NULL; + CAPIerr(CAPI_F_WIDE_TO_ASC, CAPI_R_FUNCTION_NOT_SUPPORTED); + return NULL; } len_0 = (int)len_1; /* WideCharToMultiByte expects int */ diff --git a/test/evp_extra_test.c b/test/evp_extra_test.c index 99189a20b33..7ca72d71f93 100644 --- a/test/evp_extra_test.c +++ b/test/evp_extra_test.c @@ -3528,8 +3528,8 @@ static int test_empty_salt_info_HKDF(void) unsigned char key[] = "012345678901234567890123456789"; unsigned char info[] = ""; const unsigned char expected[] = { - 0x67, 0x12, 0xf9, 0x27, 0x8a, 0x8a, 0x3a, 0x8f, 0x7d, 0x2c, 0xa3, 0x6a, - 0xaa, 0xe9, 0xb3, 0xb9, 0x52, 0x5f, 0xe0, 0x06, + 0x67, 0x12, 0xf9, 0x27, 0x8a, 0x8a, 0x3a, 0x8f, 0x7d, 0x2c, 0xa3, 0x6a, + 0xaa, 0xe9, 0xb3, 0xb9, 0x52, 0x5f, 0xe0, 0x06, }; size_t expectedlen = sizeof(expected); diff --git a/test/fake_rsaprov.c b/test/fake_rsaprov.c index dab604419fc..9948c381e8b 100644 --- a/test/fake_rsaprov.c +++ b/test/fake_rsaprov.c @@ -636,7 +636,7 @@ static int fake_rsa_st_load(void *loaderctx, if (key_deleted == 1) { *storectx = 1; break; - } + } /* Construct a new key using our keymgmt functions */ if (!TEST_ptr(key = fake_rsa_keymgmt_new(NULL))) diff --git a/test/provider_pkey_test.c b/test/provider_pkey_test.c index cb656a62a65..128f2138ff9 100644 --- a/test/provider_pkey_test.c +++ b/test/provider_pkey_test.c @@ -345,9 +345,9 @@ static int test_pkey_delete(void) goto end; while (!OSSL_STORE_eof(ctx)) { - info = OSSL_STORE_load(ctx); - if (!TEST_ptr_null(info)) - goto end; + info = OSSL_STORE_load(ctx); + if (!TEST_ptr_null(info)) + goto end; } ret = 1; diff --git a/test/quic_multistream_test.c b/test/quic_multistream_test.c index 0849b5773a0..e262dfd4670 100644 --- a/test/quic_multistream_test.c +++ b/test/quic_multistream_test.c @@ -82,8 +82,8 @@ struct helper { #if defined(OPENSSL_THREADS) struct child_thread_args *threads; size_t num_threads; - CRYPTO_MUTEX *misc_m; - CRYPTO_CONDVAR *misc_cv; + CRYPTO_MUTEX *misc_m; + CRYPTO_CONDVAR *misc_cv; #endif OSSL_TIME start_time;