From 8ee2422ef8d5287f0e236e954992178624478c71 Mon Sep 17 00:00:00 2001 From: niisato Date: Mon, 25 Jun 2018 19:05:48 +0900 Subject: [PATCH 1/5] about a issue Replace "new" variable #1782 --- library/ssl_tls.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/library/ssl_tls.c b/library/ssl_tls.c index e5119fcda..fd33fa41c 100644 --- a/library/ssl_tls.c +++ b/library/ssl_tls.c @@ -5995,27 +5995,27 @@ static int ssl_append_key_cert( mbedtls_ssl_key_cert **head, mbedtls_x509_crt *cert, mbedtls_pk_context *key ) { - mbedtls_ssl_key_cert *new; + mbedtls_ssl_key_cert *new_cert; - new = mbedtls_calloc( 1, sizeof( mbedtls_ssl_key_cert ) ); - if( new == NULL ) + new_cert = mbedtls_calloc( 1, sizeof( mbedtls_ssl_key_cert ) ); + if( new_cert == NULL ) return( MBEDTLS_ERR_SSL_ALLOC_FAILED ); - new->cert = cert; - new->key = key; - new->next = NULL; + new_cert->cert = cert; + new_cert->key = key; + new_cert->next = NULL; /* Update head is the list was null, else add to the end */ if( *head == NULL ) { - *head = new; + *head = new_cert; } else { mbedtls_ssl_key_cert *cur = *head; while( cur->next != NULL ) cur = cur->next; - cur->next = new; + cur->next = new_cert; } return( 0 ); From 15550854a372887752a164eed2d451c0c5b31b03 Mon Sep 17 00:00:00 2001 From: niisato Date: Mon, 25 Jun 2018 20:07:10 +0900 Subject: [PATCH 2/5] add ChangeLog to this commit. --- ChangeLog | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/ChangeLog b/ChangeLog index 027a97174..85120e23f 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,13 @@ mbed TLS ChangeLog (Sorted per branch, date) + += mbed TLS x.x.x branch released xxxx-xx-xx + +Bugfix + * Fix Renaming "new" variable #1783. + compile error(new variable) with arm-none-eabi-gcc(c++) on mbed TLS 2.7.0. + + = mbed TLS 2.11.0 branch released 2018-06-18 Features From 99a3e8072138e097df42acabfd9ea49541ac4659 Mon Sep 17 00:00:00 2001 From: niisato Date: Mon, 25 Jun 2018 20:21:19 +0900 Subject: [PATCH 3/5] update change log. --- ChangeLog | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/ChangeLog b/ChangeLog index 85120e23f..f22383217 100644 --- a/ChangeLog +++ b/ChangeLog @@ -4,9 +4,7 @@ mbed TLS ChangeLog (Sorted per branch, date) = mbed TLS x.x.x branch released xxxx-xx-xx Bugfix - * Fix Renaming "new" variable #1783. - compile error(new variable) with arm-none-eabi-gcc(c++) on mbed TLS 2.7.0. - + * Fix compilation error on c++, because of a variable named new. Found and fixed by Hirotaka Niisato in #1783 = mbed TLS 2.11.0 branch released 2018-06-18 From b7d39db047bb758897ca4f96b9f2f32b50224ce5 Mon Sep 17 00:00:00 2001 From: niisato Date: Mon, 25 Jun 2018 20:44:57 +0900 Subject: [PATCH 4/5] update ChangeLog --- ChangeLog | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index f22383217..70c000a31 100644 --- a/ChangeLog +++ b/ChangeLog @@ -4,7 +4,8 @@ mbed TLS ChangeLog (Sorted per branch, date) = mbed TLS x.x.x branch released xxxx-xx-xx Bugfix - * Fix compilation error on c++, because of a variable named new. Found and fixed by Hirotaka Niisato in #1783 + * Fix compilation error on C++, because of a variable named new. + Found and fixed by Hirotaka Niisato in #1783 = mbed TLS 2.11.0 branch released 2018-06-18 From 164b9cd025bdfcc2becea310045fae11def65149 Mon Sep 17 00:00:00 2001 From: niisato Date: Mon, 25 Jun 2018 20:47:05 +0900 Subject: [PATCH 5/5] update ChangeLog --- ChangeLog | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 70c000a31..25facc53f 100644 --- a/ChangeLog +++ b/ChangeLog @@ -5,7 +5,7 @@ mbed TLS ChangeLog (Sorted per branch, date) Bugfix * Fix compilation error on C++, because of a variable named new. - Found and fixed by Hirotaka Niisato in #1783 + Found and fixed by Hirotaka Niisato in #1783. = mbed TLS 2.11.0 branch released 2018-06-18