Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/boringssl.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Benjamin <davidben@chromium.org>2014-08-30 22:54:37 +0400
committerAdam Langley <agl@google.com>2014-09-03 03:41:22 +0400
commit120a674c003b2e5950d77415c464b5db20c43972 (patch)
tree8c44a5966dceb7b5ac50d0571095ae08eeb06f86 /ssl/t1_lib.c
parent5c24a1d6b67fd4a39ad7e34930763d85dd4b4b84 (diff)
Fix the return values for most of SRTP.
Switch all of SRTP code to the standard return value convention with two exceptions. Unfortunately, OpenSSL exposed API with the wrong error code. Keep the public API flipped and document. Change-Id: I43ac82513f4f52bb36a0b54aba9b9e0fa285730e Reviewed-on: https://boringssl-review.googlesource.com/1691 Reviewed-by: Adam Langley <agl@google.com>
Diffstat (limited to 'ssl/t1_lib.c')
-rw-r--r--ssl/t1_lib.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/ssl/t1_lib.c b/ssl/t1_lib.c
index 1af521f3..b9553a55 100644
--- a/ssl/t1_lib.c
+++ b/ssl/t1_lib.c
@@ -1099,7 +1099,7 @@ unsigned char *ssl_add_clienthello_tlsext(SSL *s, unsigned char *buf, unsigned c
s2n(TLSEXT_TYPE_use_srtp,ret);
s2n(el,ret);
- if(ssl_add_clienthello_use_srtp_ext(s, ret, &el, el))
+ if(!ssl_add_clienthello_use_srtp_ext(s, ret, &el, el))
{
OPENSSL_PUT_ERROR(SSL, ssl_add_clienthello_tlsext, ERR_R_INTERNAL_ERROR);
return NULL;
@@ -1296,7 +1296,7 @@ unsigned char *ssl_add_serverhello_tlsext(SSL *s, unsigned char *buf, unsigned c
s2n(TLSEXT_TYPE_use_srtp,ret);
s2n(el,ret);
- if(ssl_add_serverhello_use_srtp_ext(s, ret, &el, el))
+ if(!ssl_add_serverhello_use_srtp_ext(s, ret, &el, el))
{
OPENSSL_PUT_ERROR(SSL, ssl_add_serverhello_tlsext, ERR_R_INTERNAL_ERROR);
return NULL;