diff --git a/components/tcp_transport/transport.c b/components/tcp_transport/transport.c index 3ea382e407..902786cf0d 100644 --- a/components/tcp_transport/transport.c +++ b/components/tcp_transport/transport.c @@ -1,16 +1,8 @@ -// Copyright 2015-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: 2015-2022 Espressif Systems (Shanghai) CO LTD + * + * SPDX-License-Identifier: Apache-2.0 + */ #include @@ -310,7 +302,7 @@ esp_err_t esp_transport_set_parent_transport_func(esp_transport_handle_t t, payl esp_tls_error_handle_t esp_transport_get_error_handle(esp_transport_handle_t t) { - if (t) { + if (t && t->base && t->base->error_handle) { return &t->base->error_handle->esp_tls_err_h_base; } return NULL; diff --git a/tools/ci/check_copyright_ignore.txt b/tools/ci/check_copyright_ignore.txt index 690bb6877c..8d28b77366 100644 --- a/tools/ci/check_copyright_ignore.txt +++ b/tools/ci/check_copyright_ignore.txt @@ -2131,7 +2131,6 @@ components/tcp_transport/test/tcp_transport_fixtures.h components/tcp_transport/test/test_transport_basic.c components/tcp_transport/test/test_transport_connect.c components/tcp_transport/test/test_transport_fixtures.c -components/tcp_transport/transport.c components/tcp_transport/transport_ssl.c components/tcp_transport/transport_utils.c components/tcpip_adapter/include/tcpip_adapter.h