summaryrefslogtreecommitdiff
path: root/src/lib/libssl/d1_srtp.c
diff options
context:
space:
mode:
authortb <>2018-11-09 04:35:09 +0000
committertb <>2018-11-09 04:35:09 +0000
commit32afc0b03b3b4e8d5e68f0f727c56ba151ba864f (patch)
tree7af540c19a4d1e50ba302fc38e2b396aaece28a4 /src/lib/libssl/d1_srtp.c
parentdedace976f6f0b10e4b1548a628f5a724c541101 (diff)
downloadopenbsd-32afc0b03b3b4e8d5e68f0f727c56ba151ba864f.tar.gz
openbsd-32afc0b03b3b4e8d5e68f0f727c56ba151ba864f.tar.bz2
openbsd-32afc0b03b3b4e8d5e68f0f727c56ba151ba864f.zip
Avoid leak: free existing SRTP connection profiles before
setting it. From Ben L <bobsayshilol () live ! co ! uk>.
Diffstat (limited to 'src/lib/libssl/d1_srtp.c')
-rw-r--r--src/lib/libssl/d1_srtp.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/lib/libssl/d1_srtp.c b/src/lib/libssl/d1_srtp.c
index eb1877a12c..4b1b24a3c1 100644
--- a/src/lib/libssl/d1_srtp.c
+++ b/src/lib/libssl/d1_srtp.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: d1_srtp.c,v 1.22 2017/08/27 02:58:04 doug Exp $ */ 1/* $OpenBSD: d1_srtp.c,v 1.23 2018/11/09 04:35:09 tb 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 *
@@ -207,6 +207,7 @@ ssl_ctx_make_profiles(const char *profiles_string,
207 ptr = col + 1; 207 ptr = col + 1;
208 } while (col); 208 } while (col);
209 209
210 sk_SRTP_PROTECTION_PROFILE_free(*out);
210 *out = profiles; 211 *out = profiles;
211 212
212 return 0; 213 return 0;