summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/lib/libcrypto/conf/conf_def.c5
-rw-r--r--src/lib/libssl/src/crypto/conf/conf_def.c5
2 files changed, 4 insertions, 6 deletions
diff --git a/src/lib/libcrypto/conf/conf_def.c b/src/lib/libcrypto/conf/conf_def.c
index e608e5fe9d..5526fa5c03 100644
--- a/src/lib/libcrypto/conf/conf_def.c
+++ b/src/lib/libcrypto/conf/conf_def.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: conf_def.c,v 1.29 2015/02/07 13:19:15 doug Exp $ */ 1/* $OpenBSD: conf_def.c,v 1.30 2015/04/30 15:28:03 deraadt Exp $ */
2/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) 2/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com)
3 * All rights reserved. 3 * All rights reserved.
4 * 4 *
@@ -228,12 +228,11 @@ def_load_bio(CONF *conf, BIO *in, long *line)
228 goto err; 228 goto err;
229 } 229 }
230 230
231 section = malloc(10); 231 section = strdup("default");
232 if (section == NULL) { 232 if (section == NULL) {
233 CONFerr(CONF_F_DEF_LOAD_BIO, ERR_R_MALLOC_FAILURE); 233 CONFerr(CONF_F_DEF_LOAD_BIO, ERR_R_MALLOC_FAILURE);
234 goto err; 234 goto err;
235 } 235 }
236 strlcpy(section, "default",10);
237 236
238 if (_CONF_new_data(conf) == 0) { 237 if (_CONF_new_data(conf) == 0) {
239 CONFerr(CONF_F_DEF_LOAD_BIO, ERR_R_MALLOC_FAILURE); 238 CONFerr(CONF_F_DEF_LOAD_BIO, ERR_R_MALLOC_FAILURE);
diff --git a/src/lib/libssl/src/crypto/conf/conf_def.c b/src/lib/libssl/src/crypto/conf/conf_def.c
index e608e5fe9d..5526fa5c03 100644
--- a/src/lib/libssl/src/crypto/conf/conf_def.c
+++ b/src/lib/libssl/src/crypto/conf/conf_def.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: conf_def.c,v 1.29 2015/02/07 13:19:15 doug Exp $ */ 1/* $OpenBSD: conf_def.c,v 1.30 2015/04/30 15:28:03 deraadt Exp $ */
2/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) 2/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com)
3 * All rights reserved. 3 * All rights reserved.
4 * 4 *
@@ -228,12 +228,11 @@ def_load_bio(CONF *conf, BIO *in, long *line)
228 goto err; 228 goto err;
229 } 229 }
230 230
231 section = malloc(10); 231 section = strdup("default");
232 if (section == NULL) { 232 if (section == NULL) {
233 CONFerr(CONF_F_DEF_LOAD_BIO, ERR_R_MALLOC_FAILURE); 233 CONFerr(CONF_F_DEF_LOAD_BIO, ERR_R_MALLOC_FAILURE);
234 goto err; 234 goto err;
235 } 235 }
236 strlcpy(section, "default",10);
237 236
238 if (_CONF_new_data(conf) == 0) { 237 if (_CONF_new_data(conf) == 0) {
239 CONFerr(CONF_F_DEF_LOAD_BIO, ERR_R_MALLOC_FAILURE); 238 CONFerr(CONF_F_DEF_LOAD_BIO, ERR_R_MALLOC_FAILURE);