From c000673540416965bdfba92ce092bab924fc4740 Mon Sep 17 00:00:00 2001 From: "lorenzo.consolaro" Date: Tue, 8 Mar 2022 14:47:51 +0100 Subject: [PATCH 1/2] protocomm: Fix debug print on encrypting failure Closes https://github.com/espressif/esp-idf/pull/8526 --- components/protocomm/src/common/protocomm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/components/protocomm/src/common/protocomm.c b/components/protocomm/src/common/protocomm.c index cdfd8d7965..f505ba2dee 100644 --- a/components/protocomm/src/common/protocomm.c +++ b/components/protocomm/src/common/protocomm.c @@ -240,7 +240,7 @@ esp_err_t protocomm_req_handle(protocomm_t *pc, const char *ep_name, uint32_t se /* Encrypt response to be sent back */ uint8_t *enc_resp = (uint8_t *) malloc(plaintext_resp_len); if (!enc_resp) { - ESP_LOGE(TAG, "Failed to allocate decrypt buf len %d", inlen); + ESP_LOGE(TAG, "Failed to allocate encrypt buf len %d", plaintext_resp_len); free(plaintext_resp); return ESP_ERR_NO_MEM; } From 3b0cb10b9d2f476446778fbca8003f8dc0856973 Mon Sep 17 00:00:00 2001 From: Mahavir Jain Date: Fri, 11 Mar 2022 09:17:20 +0530 Subject: [PATCH 2/2] protocomm: fix copyright header --- components/protocomm/src/common/protocomm.c | 18 +++++------------- tools/ci/check_copyright_ignore.txt | 1 - 2 files changed, 5 insertions(+), 14 deletions(-) diff --git a/components/protocomm/src/common/protocomm.c b/components/protocomm/src/common/protocomm.c index f505ba2dee..9af6fe6f3c 100644 --- a/components/protocomm/src/common/protocomm.c +++ b/components/protocomm/src/common/protocomm.c @@ -1,16 +1,8 @@ -// Copyright 2018 Espressif Systems (Shanghai) PTE LTD -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. +/* + * SPDX-FileCopyrightText: 2018-2022 Espressif Systems (Shanghai) CO LTD + * + * SPDX-License-Identifier: Apache-2.0 + */ #include #include diff --git a/tools/ci/check_copyright_ignore.txt b/tools/ci/check_copyright_ignore.txt index 2f6771ea48..0bde9d7fb2 100644 --- a/tools/ci/check_copyright_ignore.txt +++ b/tools/ci/check_copyright_ignore.txt @@ -1248,7 +1248,6 @@ components/protocomm/python/constants_pb2.py components/protocomm/python/sec0_pb2.py components/protocomm/python/sec1_pb2.py components/protocomm/python/session_pb2.py -components/protocomm/src/common/protocomm.c components/protocomm/src/common/protocomm_priv.h components/protocomm/src/security/security0.c components/pthread/pthread_cond_var.c