summaryrefslogtreecommitdiff
path: root/src/lib/libcrypto/rand/rand_err.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/libcrypto/rand/rand_err.c')
-rw-r--r--src/lib/libcrypto/rand/rand_err.c28
1 files changed, 12 insertions, 16 deletions
diff --git a/src/lib/libcrypto/rand/rand_err.c b/src/lib/libcrypto/rand/rand_err.c
index 97f96e1aee..95574659ac 100644
--- a/src/lib/libcrypto/rand/rand_err.c
+++ b/src/lib/libcrypto/rand/rand_err.c
@@ -1,6 +1,6 @@
1/* crypto/rand/rand_err.c */ 1/* crypto/rand/rand_err.c */
2/* ==================================================================== 2/* ====================================================================
3 * Copyright (c) 1999-2005 The OpenSSL Project. All rights reserved. 3 * Copyright (c) 1999-2003 The OpenSSL Project. All rights reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
@@ -64,26 +64,22 @@
64 64
65/* BEGIN ERROR CODES */ 65/* BEGIN ERROR CODES */
66#ifndef OPENSSL_NO_ERR 66#ifndef OPENSSL_NO_ERR
67
68#define ERR_FUNC(func) ERR_PACK(ERR_LIB_RAND,func,0)
69#define ERR_REASON(reason) ERR_PACK(ERR_LIB_RAND,0,reason)
70
71static ERR_STRING_DATA RAND_str_functs[]= 67static ERR_STRING_DATA RAND_str_functs[]=
72 { 68 {
73{ERR_FUNC(RAND_F_FIPS_RAND_BYTES), "FIPS_RAND_BYTES"}, 69{ERR_PACK(0,RAND_F_FIPS_RAND_BYTES,0), "FIPS_RAND_BYTES"},
74{ERR_FUNC(RAND_F_RAND_GET_RAND_METHOD), "RAND_get_rand_method"}, 70{ERR_PACK(0,RAND_F_RAND_GET_RAND_METHOD,0), "RAND_get_rand_method"},
75{ERR_FUNC(RAND_F_SSLEAY_RAND_BYTES), "SSLEAY_RAND_BYTES"}, 71{ERR_PACK(0,RAND_F_SSLEAY_RAND_BYTES,0), "SSLEAY_RAND_BYTES"},
76{0,NULL} 72{0,NULL}
77 }; 73 };
78 74
79static ERR_STRING_DATA RAND_str_reasons[]= 75static ERR_STRING_DATA RAND_str_reasons[]=
80 { 76 {
81{ERR_REASON(RAND_R_NON_FIPS_METHOD) ,"non fips method"}, 77{RAND_R_NON_FIPS_METHOD ,"non fips method"},
82{ERR_REASON(RAND_R_PRNG_ASKING_FOR_TOO_MUCH),"prng asking for too much"}, 78{RAND_R_PRNG_ASKING_FOR_TOO_MUCH ,"prng asking for too much"},
83{ERR_REASON(RAND_R_PRNG_NOT_REKEYED) ,"prng not rekeyed"}, 79{RAND_R_PRNG_NOT_REKEYED ,"prng not rekeyed"},
84{ERR_REASON(RAND_R_PRNG_NOT_RESEEDED) ,"prng not reseeded"}, 80{RAND_R_PRNG_NOT_RESEEDED ,"prng not reseeded"},
85{ERR_REASON(RAND_R_PRNG_NOT_SEEDED) ,"PRNG not seeded"}, 81{RAND_R_PRNG_NOT_SEEDED ,"PRNG not seeded"},
86{ERR_REASON(RAND_R_PRNG_STUCK) ,"prng stuck"}, 82{RAND_R_PRNG_STUCK ,"prng stuck"},
87{0,NULL} 83{0,NULL}
88 }; 84 };
89 85
@@ -97,8 +93,8 @@ void ERR_load_RAND_strings(void)
97 { 93 {
98 init=0; 94 init=0;
99#ifndef OPENSSL_NO_ERR 95#ifndef OPENSSL_NO_ERR
100 ERR_load_strings(0,RAND_str_functs); 96 ERR_load_strings(ERR_LIB_RAND,RAND_str_functs);
101 ERR_load_strings(0,RAND_str_reasons); 97 ERR_load_strings(ERR_LIB_RAND,RAND_str_reasons);
102#endif 98#endif
103 99
104 } 100 }