From 201c85478e2ed1851172ff8001dad3fe718d5fb1 Mon Sep 17 00:00:00 2001 From: John Safranek Date: Thu, 21 Feb 2019 10:28:23 -0800 Subject: [PATCH] Move the -5 option text into the localization array and add a Japanese translation. --- examples/client/client.c | 14 +++++++++++--- examples/server/server.c | 9 +++++++-- 2 files changed, 18 insertions(+), 5 deletions(-) diff --git a/examples/client/client.c b/examples/client/client.c index cd72d5253..7c9ef25cf 100644 --- a/examples/client/client.c +++ b/examples/client/client.c @@ -988,7 +988,12 @@ static const char* client_usage_msg[][59] = { !defined(HAVE_SELFTEST) && !defined(WOLFSSL_OLD_PRIME_CHECK) "-2 Disable DH Prime check\n", /* 59 */ #endif +#ifdef HAVE_SECURE_RENEGOTIATION "-4 Use resumption for renegotiation\n", /* 60 */ +#endif +#ifdef HAVE_TRUSTED_CA + "-5 Use Trusted CA Key Indication\n", /* 61 */ +#endif NULL, }, #ifndef NO_MULTIBYTE_PRINT @@ -1146,6 +1151,9 @@ static const char* client_usage_msg[][59] = { #endif #ifdef HAVE_SECURE_RENEGOTIATION "-4 再交渉に再開を使用\n", /* 60 */ +#endif +#ifdef HAVE_TRUSTED_CA + "-5 信頼できる認証局の鍵表示を使用する\n", /* 61 */ #endif NULL, }, @@ -1290,9 +1298,6 @@ static void Usage(void) #endif #ifdef WOLFSSL_MULTICAST printf("%s", msg[++msgid]); /* -3 */ -#endif -#ifdef HAVE_TRUSTED_CA - printf("-5 Use Trusted CA Key Indication\n"); #endif printf("%s", msg[++msgid]); /* -1 */ #if !defined(NO_DH) && !defined(HAVE_FIPS) && \ @@ -1302,6 +1307,9 @@ static void Usage(void) #ifdef HAVE_SECURE_RENEGOTIATION printf("%s", msg[++msgid]); /* -4 */ #endif +#ifdef HAVE_TRUSTED_CA + printf("%s", msg[++msgid]); /* -5 */ +#endif } THREAD_RETURN WOLFSSL_THREAD client_test(void* args) diff --git a/examples/server/server.c b/examples/server/server.c index 8e4221e8f..4eda55701 100644 --- a/examples/server/server.c +++ b/examples/server/server.c @@ -594,6 +594,9 @@ static const char* server_usage_msg[][49] = { #endif "-1 Display a result by specified language." "\n 0: English, 1: Japanese\n", /* 48 */ +#ifdef HAVE_TRUSTED_CA + "-5 Use Trusted CA Key Indication\n", /* 51 */ +#endif NULL, }, #ifndef NO_MULTIBYTE_PRINT @@ -709,10 +712,12 @@ static const char* server_usage_msg[][49] = { #endif "-1 指定された言語で結果を表示します。" "\n 0: 英語、 1: 日本語\n", /* 48 */ +#ifdef HAVE_TRUSTED_CA + "-5 信頼できる認証局の鍵表示を使用する\n", /* 51 */ +#endif NULL, }, #endif - }; static void Usage(void) @@ -826,7 +831,7 @@ static void Usage(void) #endif printf("%s", msg[++msgId]); /* -1 */ #ifdef HAVE_TRUSTED_CA - printf("-5 Use Trusted CA Key Indication\n"); + printf("%s", msg[++msgId]); /* -5 */ #endif /* HAVE_TRUSTED_CA */ }