From bc15f67d8da81e2322d24717b3344df2184f52eb Mon Sep 17 00:00:00 2001 From: Andras Fekete Date: Mon, 19 Dec 2022 11:13:58 -0500 Subject: [PATCH] Fixing indentation on preprocessor commands --- .../ESP-IDF/examples/wolfssl_client/main/wifi_connect.c | 6 +++--- .../ESP-IDF/examples/wolfssl_server/main/wifi_connect.c | 6 +++--- wolfcrypt/benchmark/benchmark.c | 6 +++--- wolfcrypt/src/port/Espressif/esp32_aes.c | 6 +++--- wolfcrypt/src/port/Espressif/esp32_sha.c | 6 +++--- wolfssl/wolfcrypt/wc_port.h | 4 ++-- 6 files changed, 17 insertions(+), 17 deletions(-) diff --git a/IDE/Espressif/ESP-IDF/examples/wolfssl_client/main/wifi_connect.c b/IDE/Espressif/ESP-IDF/examples/wolfssl_client/main/wifi_connect.c index c9c87e368..7379c7aa5 100644 --- a/IDE/Espressif/ESP-IDF/examples/wolfssl_client/main/wifi_connect.c +++ b/IDE/Espressif/ESP-IDF/examples/wolfssl_client/main/wifi_connect.c @@ -78,11 +78,11 @@ static void set_time() static void tls_smp_client_init(void) { int ret; - #if ESP_IDF_VERSION_MAJOR >= 4 +#if ESP_IDF_VERSION_MAJOR >= 4 TaskHandle_t _handle; - #else +#else xTaskHandle _handle; - #endif +#endif /* http://esp32.info/docs/esp_idf/html/dd/d3c/group__xTaskCreate.html */ ret = xTaskCreate(tls_smp_client_task, TLS_SMP_CLIENT_TASK_NAME, diff --git a/IDE/Espressif/ESP-IDF/examples/wolfssl_server/main/wifi_connect.c b/IDE/Espressif/ESP-IDF/examples/wolfssl_server/main/wifi_connect.c index 672c85fe2..d05983905 100644 --- a/IDE/Espressif/ESP-IDF/examples/wolfssl_server/main/wifi_connect.c +++ b/IDE/Espressif/ESP-IDF/examples/wolfssl_server/main/wifi_connect.c @@ -78,11 +78,11 @@ static void set_time() static void tls_smp_server_init(void) { int ret; - #if ESP_IDF_VERSION_MAJOR >= 4 +#if ESP_IDF_VERSION_MAJOR >= 4 TaskHandle_t _handle; - #else +#else xTaskHandle _handle; - #endif +#endif /* http://esp32.info/docs/esp_idf/html/dd/d3c/group__xTaskCreate.html */ ret = xTaskCreate(tls_smp_server_task, TLS_SMP_SERVER_TASK_NAME, diff --git a/wolfcrypt/benchmark/benchmark.c b/wolfcrypt/benchmark/benchmark.c index 1b5e9be76..87aa743f5 100644 --- a/wolfcrypt/benchmark/benchmark.c +++ b/wolfcrypt/benchmark/benchmark.c @@ -8216,11 +8216,11 @@ void bench_sphincsKeySign(byte level, byte optim) #endif double current_time(int reset) { - #if ESP_IDF_VERSION_MAJOR >= 4 + #if ESP_IDF_VERSION_MAJOR >= 4 TickType_t tickCount; - #else + #else portTickType tickCount; - #endif + #endif (void) reset; diff --git a/wolfcrypt/src/port/Espressif/esp32_aes.c b/wolfcrypt/src/port/Espressif/esp32_aes.c index 8aefd491f..062cd8bad 100644 --- a/wolfcrypt/src/port/Espressif/esp32_aes.c +++ b/wolfcrypt/src/port/Espressif/esp32_aes.c @@ -157,11 +157,11 @@ static void esp_aes_hw_Set_KeyMode(Aes *ctx, ESP32_AESPROCESS mode) static void esp_aes_bk(const byte* in, byte* out) { const word32 *inwords = (const word32 *)in; - #if ESP_IDF_VERSION_MAJOR >= 4 +#if ESP_IDF_VERSION_MAJOR >= 4 uint32_t *outwords = (uint32_t *)out; - #else +#else word32 *outwords = (word32 *)out; - #endif +#endif ESP_LOGV(TAG, "enter esp_aes_bk"); diff --git a/wolfcrypt/src/port/Espressif/esp32_sha.c b/wolfcrypt/src/port/Espressif/esp32_sha.c index f63ce5a70..2910291b1 100644 --- a/wolfcrypt/src/port/Espressif/esp32_sha.c +++ b/wolfcrypt/src/port/Espressif/esp32_sha.c @@ -551,11 +551,11 @@ int wc_esp_digest_state(WC_ESP32SHA* ctx, byte* hash) * DPORT_SEQUENCE_REG_READ(address + i * 4); */ esp_dport_access_read_buffer( - #if ESP_IDF_VERSION_MAJOR >= 4 +#if ESP_IDF_VERSION_MAJOR >= 4 (uint32_t*)(hash), /* the result will be found in hash upon exit */ - #else +#else (word32*)(hash), /* the result will be found in hash upon exit */ - #endif +#endif SHA_TEXT_BASE, /* there's a fixed reg addy for all SHA */ wc_esp_sha_digest_size(ctx->sha_type) / sizeof(word32) /* # 4-byte */ ); diff --git a/wolfssl/wolfcrypt/wc_port.h b/wolfssl/wolfcrypt/wc_port.h index 6ff1c2761..b5bdbba4c 100644 --- a/wolfssl/wolfcrypt/wc_port.h +++ b/wolfssl/wolfcrypt/wc_port.h @@ -203,9 +203,9 @@ /* FREERTOS comes first to enable use of FreeRTOS Windows simulator only */ #if defined(FREERTOS) #if ESP_IDF_VERSION_MAJOR >= 4 - typedef SemaphoreHandle_t wolfSSL_Mutex; + typedef SemaphoreHandle_t wolfSSL_Mutex; #else - typedef xSemaphoreHandle wolfSSL_Mutex; + typedef xSemaphoreHandle wolfSSL_Mutex; #endif #elif defined(FREERTOS_TCP) #include "FreeRTOS.h"