summaryrefslogtreecommitdiff
path: root/src/lib/libssl/d1_lib.c
diff options
context:
space:
mode:
authordoug <>2015-07-19 20:32:18 +0000
committerdoug <>2015-07-19 20:32:18 +0000
commite1b84c43076222a250e436e71045972c584515ce (patch)
treecbd31a1076f71b0161d2ea3b691a126f3d856a33 /src/lib/libssl/d1_lib.c
parent243442e0f6d87748dcaccc2d2d3bf5605be3e3a9 (diff)
downloadopenbsd-e1b84c43076222a250e436e71045972c584515ce.tar.gz
openbsd-e1b84c43076222a250e436e71045972c584515ce.tar.bz2
openbsd-e1b84c43076222a250e436e71045972c584515ce.zip
Allow *_free() functions in libssl to handle NULL input.
This mimics free()'s behavior which makes error handling simpler. ok bcook@ miod@
Diffstat (limited to '')
-rw-r--r--src/lib/libssl/d1_lib.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/lib/libssl/d1_lib.c b/src/lib/libssl/d1_lib.c
index dd789ccc70..b269efe469 100644
--- a/src/lib/libssl/d1_lib.c
+++ b/src/lib/libssl/d1_lib.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: d1_lib.c,v 1.28 2015/03/19 14:00:22 tedu Exp $ */ 1/* $OpenBSD: d1_lib.c,v 1.29 2015/07/19 20:32:18 doug Exp $ */
2/* 2/*
3 * DTLS implementation written by Nagendra Modadugu 3 * DTLS implementation written by Nagendra Modadugu
4 * (nagendra@cs.stanford.edu) for the OpenSSL project 2005. 4 * (nagendra@cs.stanford.edu) for the OpenSSL project 2005.
@@ -190,6 +190,9 @@ dtls1_clear_queues(SSL *s)
190void 190void
191dtls1_free(SSL *s) 191dtls1_free(SSL *s)
192{ 192{
193 if (s == NULL)
194 return;
195
193 ssl3_free(s); 196 ssl3_free(s);
194 197
195 dtls1_clear_queues(s); 198 dtls1_clear_queues(s);