diff options
| author | beck <> | 2017-01-29 17:49:23 +0000 |
|---|---|---|
| committer | beck <> | 2017-01-29 17:49:23 +0000 |
| commit | d1f47bd292f36094480caa49ada36b99a69c59b0 (patch) | |
| tree | 1a54abba678898ee5270ae4f3404a50ee9a92eea /src/lib/libcrypto/objects/o_names.c | |
| parent | f8c627888330b75c2eea8a3c27d0efe947a4f9da (diff) | |
| download | openbsd-d1f47bd292f36094480caa49ada36b99a69c59b0.tar.gz openbsd-d1f47bd292f36094480caa49ada36b99a69c59b0.tar.bz2 openbsd-d1f47bd292f36094480caa49ada36b99a69c59b0.zip | |
Send the function codes from the error functions to the bit bucket,
as was done earlier in libssl. Thanks inoguchi@ for noticing
libssl had more reacharounds into this.
ok jsing@ inoguchi@
Diffstat (limited to 'src/lib/libcrypto/objects/o_names.c')
| -rw-r--r-- | src/lib/libcrypto/objects/o_names.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/lib/libcrypto/objects/o_names.c b/src/lib/libcrypto/objects/o_names.c index 81240db204..a9e5f859d5 100644 --- a/src/lib/libcrypto/objects/o_names.c +++ b/src/lib/libcrypto/objects/o_names.c | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | /* $OpenBSD: o_names.c,v 1.21 2015/07/18 21:21:28 beck Exp $ */ | 1 | /* $OpenBSD: o_names.c,v 1.22 2017/01/29 17:49:23 beck Exp $ */ |
| 2 | #include <stdio.h> | 2 | #include <stdio.h> |
| 3 | #include <stdlib.h> | 3 | #include <stdlib.h> |
| 4 | #include <string.h> | 4 | #include <string.h> |
| @@ -67,7 +67,7 @@ OBJ_NAME_new_index(unsigned long (*hash_func)(const char *), | |||
| 67 | for (i = sk_NAME_FUNCS_num(name_funcs_stack); i < names_type_num; i++) { | 67 | for (i = sk_NAME_FUNCS_num(name_funcs_stack); i < names_type_num; i++) { |
| 68 | name_funcs = malloc(sizeof(NAME_FUNCS)); | 68 | name_funcs = malloc(sizeof(NAME_FUNCS)); |
| 69 | if (!name_funcs) { | 69 | if (!name_funcs) { |
| 70 | OBJerr(OBJ_F_OBJ_NAME_NEW_INDEX, ERR_R_MALLOC_FAILURE); | 70 | OBJerror(ERR_R_MALLOC_FAILURE); |
| 71 | return (0); | 71 | return (0); |
| 72 | } | 72 | } |
| 73 | name_funcs->hash_func = lh_strhash; | 73 | name_funcs->hash_func = lh_strhash; |
| @@ -75,7 +75,7 @@ OBJ_NAME_new_index(unsigned long (*hash_func)(const char *), | |||
| 75 | name_funcs->free_func = NULL; | 75 | name_funcs->free_func = NULL; |
| 76 | if (sk_NAME_FUNCS_push(name_funcs_stack, name_funcs) == 0) { | 76 | if (sk_NAME_FUNCS_push(name_funcs_stack, name_funcs) == 0) { |
| 77 | free(name_funcs); | 77 | free(name_funcs); |
| 78 | OBJerr(OBJ_F_OBJ_NAME_NEW_INDEX, ERR_R_MALLOC_FAILURE); | 78 | OBJerror(ERR_R_MALLOC_FAILURE); |
| 79 | return (0); | 79 | return (0); |
| 80 | } | 80 | } |
| 81 | } | 81 | } |
