diff options
Diffstat (limited to 'src/lib/libcrypto/ui/ui_err.c')
| -rw-r--r-- | src/lib/libcrypto/ui/ui_err.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/src/lib/libcrypto/ui/ui_err.c b/src/lib/libcrypto/ui/ui_err.c index 3f875da776..656fa42887 100644 --- a/src/lib/libcrypto/ui/ui_err.c +++ b/src/lib/libcrypto/ui/ui_err.c | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | /* $OpenBSD: ui_err.c,v 1.12 2023/02/16 08:38:17 tb Exp $ */ | 1 | /* $OpenBSD: ui_err.c,v 1.13 2024/06/24 06:43:23 tb Exp $ */ |
| 2 | /* ==================================================================== | 2 | /* ==================================================================== |
| 3 | * Copyright (c) 1999-2006 The OpenSSL Project. All rights reserved. | 3 | * Copyright (c) 1999-2006 The OpenSSL Project. All rights reserved. |
| 4 | * | 4 | * |
| @@ -60,17 +60,19 @@ | |||
| 60 | #include <openssl/err.h> | 60 | #include <openssl/err.h> |
| 61 | #include <openssl/ui.h> | 61 | #include <openssl/ui.h> |
| 62 | 62 | ||
| 63 | #include "err_local.h" | ||
| 64 | |||
| 63 | #ifndef OPENSSL_NO_ERR | 65 | #ifndef OPENSSL_NO_ERR |
| 64 | 66 | ||
| 65 | #define ERR_FUNC(func) ERR_PACK(ERR_LIB_UI,func,0) | 67 | #define ERR_FUNC(func) ERR_PACK(ERR_LIB_UI,func,0) |
| 66 | #define ERR_REASON(reason) ERR_PACK(ERR_LIB_UI,0,reason) | 68 | #define ERR_REASON(reason) ERR_PACK(ERR_LIB_UI,0,reason) |
| 67 | 69 | ||
| 68 | static ERR_STRING_DATA UI_str_functs[] = { | 70 | static const ERR_STRING_DATA UI_str_functs[] = { |
| 69 | {ERR_FUNC(0xfff), "CRYPTO_internal"}, | 71 | {ERR_FUNC(0xfff), "CRYPTO_internal"}, |
| 70 | {0, NULL} | 72 | {0, NULL} |
| 71 | }; | 73 | }; |
| 72 | 74 | ||
| 73 | static ERR_STRING_DATA UI_str_reasons[] = { | 75 | static const ERR_STRING_DATA UI_str_reasons[] = { |
| 74 | {ERR_REASON(UI_R_COMMON_OK_AND_CANCEL_CHARACTERS), "common ok and cancel characters"}, | 76 | {ERR_REASON(UI_R_COMMON_OK_AND_CANCEL_CHARACTERS), "common ok and cancel characters"}, |
| 75 | {ERR_REASON(UI_R_INDEX_TOO_LARGE), "index too large"}, | 77 | {ERR_REASON(UI_R_INDEX_TOO_LARGE), "index too large"}, |
| 76 | {ERR_REASON(UI_R_INDEX_TOO_SMALL), "index too small"}, | 78 | {ERR_REASON(UI_R_INDEX_TOO_SMALL), "index too small"}, |
| @@ -88,8 +90,8 @@ ERR_load_UI_strings(void) | |||
| 88 | { | 90 | { |
| 89 | #ifndef OPENSSL_NO_ERR | 91 | #ifndef OPENSSL_NO_ERR |
| 90 | if (ERR_func_error_string(UI_str_functs[0].error) == NULL) { | 92 | if (ERR_func_error_string(UI_str_functs[0].error) == NULL) { |
| 91 | ERR_load_strings(0, UI_str_functs); | 93 | ERR_load_const_strings(UI_str_functs); |
| 92 | ERR_load_strings(0, UI_str_reasons); | 94 | ERR_load_const_strings(UI_str_reasons); |
| 93 | } | 95 | } |
| 94 | #endif | 96 | #endif |
| 95 | } | 97 | } |
