diff options
author | Richard Levitte <levitte@openssl.org> | 2022-09-29 15:33:20 +0200 |
---|---|---|
committer | Richard Levitte <levitte@openssl.org> | 2022-10-05 14:02:03 +0200 |
commit | 79c8dcf3985a7b75eac8e53eb8652728af6c5d3d (patch) | |
tree | 9bdbc3d39d7165024fbc22971ccc9713e86ca544 /engines/e_capi_err.c | |
parent | e077455e9e57ed4ee4676996b4a9aa11df6327a6 (diff) |
Add {lib}_R_{lib}_LIB, for our engines and other "external" modules
Engines lacked the possibility to refer to themselves in this form:
WHATEVERerr(WHATEVER_F_SOMETHING, WHATEVER_R_WHATEVER_LIB);
This little change makes that possible, and gets used in e_capi.
Reviewed-by: Tomas Mraz <tomas@openssl.org>
Reviewed-by: Hugo Landau <hlandau@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/19301)
Diffstat (limited to 'engines/e_capi_err.c')
-rw-r--r-- | engines/e_capi_err.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/engines/e_capi_err.c b/engines/e_capi_err.c index 1d7636562e..8c233f01fd 100644 --- a/engines/e_capi_err.c +++ b/engines/e_capi_err.c @@ -1,6 +1,6 @@ /* * Generated by util/mkerr.pl DO NOT EDIT - * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved. + * Copyright 1995-2022 The OpenSSL Project Authors. All Rights Reserved. * * Licensed under the Apache License 2.0 (the "License"). You may not use * this file except in compliance with the License. You can obtain a copy @@ -92,3 +92,10 @@ static void ERR_CAPI_error(int function, int reason, const char *file, int line) ERR_raise(lib_code, reason); ERR_set_debug(file, line, NULL); } + +static int ERR_CAPI_lib(void) +{ + if (lib_code == 0) + lib_code = ERR_get_next_error_library(); + return lib_code; +} |