diff options
Diffstat (limited to 'src/lib/libcrypto/man/CONF_modules_load_file.3')
-rw-r--r-- | src/lib/libcrypto/man/CONF_modules_load_file.3 | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/lib/libcrypto/man/CONF_modules_load_file.3 b/src/lib/libcrypto/man/CONF_modules_load_file.3 index 900108fad4..d0401d520b 100644 --- a/src/lib/libcrypto/man/CONF_modules_load_file.3 +++ b/src/lib/libcrypto/man/CONF_modules_load_file.3 | |||
@@ -1,4 +1,4 @@ | |||
1 | .\" $OpenBSD: CONF_modules_load_file.3,v 1.7 2018/03/22 21:08:22 schwarze Exp $ | 1 | .\" $OpenBSD: CONF_modules_load_file.3,v 1.8 2019/03/20 04:02:07 schwarze Exp $ |
2 | .\" OpenSSL b97fdb57 Nov 11 09:33:09 2016 +0100 | 2 | .\" OpenSSL b97fdb57 Nov 11 09:33:09 2016 +0100 |
3 | .\" | 3 | .\" |
4 | .\" This file was written by Dr. Stephen Henson <steve@openssl.org>. | 4 | .\" This file was written by Dr. Stephen Henson <steve@openssl.org>. |
@@ -48,7 +48,7 @@ | |||
48 | .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED | 48 | .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED |
49 | .\" OF THE POSSIBILITY OF SUCH DAMAGE. | 49 | .\" OF THE POSSIBILITY OF SUCH DAMAGE. |
50 | .\" | 50 | .\" |
51 | .Dd $Mdocdate: March 22 2018 $ | 51 | .Dd $Mdocdate: March 20 2019 $ |
52 | .Dt CONF_MODULES_LOAD_FILE 3 | 52 | .Dt CONF_MODULES_LOAD_FILE 3 |
53 | .Os | 53 | .Os |
54 | .Sh NAME | 54 | .Sh NAME |
@@ -163,7 +163,7 @@ Load a configuration file and print out any errors and exit (missing | |||
163 | file considered fatal): | 163 | file considered fatal): |
164 | .Bd -literal | 164 | .Bd -literal |
165 | if (CONF_modules_load_file(NULL, NULL, 0) <= 0) { | 165 | if (CONF_modules_load_file(NULL, NULL, 0) <= 0) { |
166 | fprintf(stderr, "FATAL: error loading configuration file\n"); | 166 | fprintf(stderr, "FATAL: error loading configuration file\en"); |
167 | ERR_print_errors_fp(stderr); | 167 | ERR_print_errors_fp(stderr); |
168 | exit(1); | 168 | exit(1); |
169 | } | 169 | } |
@@ -174,7 +174,7 @@ by "myapp", tolerate missing files, but exit on other errors: | |||
174 | .Bd -literal | 174 | .Bd -literal |
175 | if (CONF_modules_load_file(NULL, "myapp", | 175 | if (CONF_modules_load_file(NULL, "myapp", |
176 | CONF_MFLAGS_IGNORE_MISSING_FILE) <= 0) { | 176 | CONF_MFLAGS_IGNORE_MISSING_FILE) <= 0) { |
177 | fprintf(stderr, "FATAL: error loading configuration file\n"); | 177 | fprintf(stderr, "FATAL: error loading configuration file\en"); |
178 | ERR_print_errors_fp(stderr); | 178 | ERR_print_errors_fp(stderr); |
179 | exit(1); | 179 | exit(1); |
180 | } | 180 | } |
@@ -185,7 +185,7 @@ error, missing configuration file ignored: | |||
185 | .Bd -literal | 185 | .Bd -literal |
186 | if (CONF_modules_load_file("/something/app.cnf", "myapp", | 186 | if (CONF_modules_load_file("/something/app.cnf", "myapp", |
187 | CONF_MFLAGS_IGNORE_MISSING_FILE) <= 0) { | 187 | CONF_MFLAGS_IGNORE_MISSING_FILE) <= 0) { |
188 | fprintf(stderr, "WARNING: error loading configuration file\n"); | 188 | fprintf(stderr, "WARNING: error loading configuration file\en"); |
189 | ERR_print_errors_fp(stderr); | 189 | ERR_print_errors_fp(stderr); |
190 | } | 190 | } |
191 | .Ed | 191 | .Ed |
@@ -198,17 +198,17 @@ long eline; | |||
198 | 198 | ||
199 | fp = fopen("/somepath/app.cnf", "r"); | 199 | fp = fopen("/somepath/app.cnf", "r"); |
200 | if (fp == NULL) { | 200 | if (fp == NULL) { |
201 | fprintf(stderr, "Error opening configuration file\n"); | 201 | fprintf(stderr, "Error opening configuration file\en"); |
202 | /* Other missing configuration file behaviour */ | 202 | /* Other missing configuration file behaviour */ |
203 | } else { | 203 | } else { |
204 | cnf = NCONF_new(NULL); | 204 | cnf = NCONF_new(NULL); |
205 | if (NCONF_load_fp(cnf, fp, &eline) == 0) { | 205 | if (NCONF_load_fp(cnf, fp, &eline) == 0) { |
206 | fprintf(stderr, "Error on line %ld of configuration file\n", | 206 | fprintf(stderr, "Error on line %ld of configuration file\en", |
207 | eline); | 207 | eline); |
208 | ERR_print_errors_fp(stderr); | 208 | ERR_print_errors_fp(stderr); |
209 | /* Other malformed configuration file behaviour */ | 209 | /* Other malformed configuration file behaviour */ |
210 | } else if (CONF_modules_load(cnf, "appname", 0) <= 0) { | 210 | } else if (CONF_modules_load(cnf, "appname", 0) <= 0) { |
211 | fprintf(stderr, "Error configuring application\n"); | 211 | fprintf(stderr, "Error configuring application\en"); |
212 | ERR_print_errors_fp(stderr); | 212 | ERR_print_errors_fp(stderr); |
213 | /* Other configuration error behaviour */ | 213 | /* Other configuration error behaviour */ |
214 | } | 214 | } |