summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorDoug Hogan <doug@cvs.openbsd.org>2015-07-18 23:00:24 +0000
committerDoug Hogan <doug@cvs.openbsd.org>2015-07-18 23:00:24 +0000
commitca45c1ef0d63dcc2d4e6aaee39b459518c1711ef (patch)
treec6a9c17243cbea3a8267079246e183dfee2faabf /lib
parent94acfb572ad3d106d6701ecfa006a616f52b1235 (diff)
Convert dtls1_get_message_header to CBS and change to int.
Changed return value from void to int. It should never return an error given that the input length is not checked yet. ok miod@
Diffstat (limited to 'lib')
-rw-r--r--lib/libssl/src/ssl/d1_pkt.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/libssl/src/ssl/d1_pkt.c b/lib/libssl/src/ssl/d1_pkt.c
index 1ff664370b4..b26ff2cec23 100644
--- a/lib/libssl/src/ssl/d1_pkt.c
+++ b/lib/libssl/src/ssl/d1_pkt.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: d1_pkt.c,v 1.44 2015/07/18 22:36:55 doug Exp $ */
+/* $OpenBSD: d1_pkt.c,v 1.45 2015/07/18 23:00:23 doug Exp $ */
/*
* DTLS implementation written by Nagendra Modadugu
* (nagendra@cs.stanford.edu) for the OpenSSL project 2005.
@@ -1018,7 +1018,8 @@ start:
struct hm_header_st msg_hdr;
/* this may just be a stale retransmit */
- dtls1_get_message_header(rr->data, &msg_hdr);
+ if (!dtls1_get_message_header(rr->data, &msg_hdr))
+ return -1;
if (rr->epoch != s->d1->r_epoch) {
rr->length = 0;
goto start;