diff --git a/src/core/ext/transport/chttp2/transport/chttp2_transport.cc b/src/core/ext/transport/chttp2/transport/chttp2_transport.cc index 900cd3cc053..e45a3cbaa15 100644 --- a/src/core/ext/transport/chttp2/transport/chttp2_transport.cc +++ b/src/core/ext/transport/chttp2/transport/chttp2_transport.cc @@ -2097,7 +2097,7 @@ static void add_error(grpc_error* error, grpc_error** refs, size_t* nrefs) { } static grpc_error* removal_error(grpc_error* extra_error, grpc_chttp2_stream* s, - const char* master_error_msg) { + const char* main_error_msg) { grpc_error* refs[3]; size_t nrefs = 0; add_error(s->read_closed_error, refs, &nrefs); @@ -2105,7 +2105,7 @@ static grpc_error* removal_error(grpc_error* extra_error, grpc_chttp2_stream* s, add_error(extra_error, refs, &nrefs); grpc_error* error = GRPC_ERROR_NONE; if (nrefs > 0) { - error = GRPC_ERROR_CREATE_REFERENCING_FROM_STATIC_STRING(master_error_msg, + error = GRPC_ERROR_CREATE_REFERENCING_FROM_STATIC_STRING(main_error_msg, refs, nrefs); } GRPC_ERROR_UNREF(extra_error); diff --git a/src/core/lib/iomgr/resource_quota.cc b/src/core/lib/iomgr/resource_quota.cc index 464cccdc861..dcbd5089bac 100644 --- a/src/core/lib/iomgr/resource_quota.cc +++ b/src/core/lib/iomgr/resource_quota.cc @@ -132,7 +132,7 @@ struct grpc_resource_quota { scaled to the range [0..RESOURCE_USAGE_ESTIMATION_MAX] */ gpr_atm memory_usage_estimation; - /* Master combiner lock: all activity on a quota executes under this combiner + /* Main combiner lock: all activity on a quota executes under this combiner * (so no mutex is needed for this data structure) */ grpc_core::Combiner* combiner; /* Size of the resource quota */ diff --git a/tools/run_tests/sanity/check_illegal_terms.sh b/tools/run_tests/sanity/check_illegal_terms.sh new file mode 100755 index 00000000000..f0d06a9c3d5 --- /dev/null +++ b/tools/run_tests/sanity/check_illegal_terms.sh @@ -0,0 +1,33 @@ +#!/bin/sh +# Copyright 2021 gRPC authors. +# +# 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. + +set -e + +cd "$(dirname "$0")/../../.." + +# +# Disallow the usage of certain terms. +# + +grep -PIirn \ + '((\b|_)(black[\ -]?hat|black[\ -]?list|black[\ -]?listed|black[\ -]?listing|dummy|grand[\ -]?father\ clause|grand[\ -]?fathered|hang|hung|man[\ -]?power|man[\ -]?hours|master(?!/)|slave|white[\ -]?hat|white[\ -]?list|white[\ -]?listed|white[\ -]?listing)(\b|_))' \ + examples \ + include \ + src/abseil-cpp \ + src/compiler \ + src/core \ + src/cpp \ + test | \ + diff - /dev/null diff --git a/tools/run_tests/sanity/sanity_tests.yaml b/tools/run_tests/sanity/sanity_tests.yaml index 9b6d3008233..f6954c425a6 100644 --- a/tools/run_tests/sanity/sanity_tests.yaml +++ b/tools/run_tests/sanity/sanity_tests.yaml @@ -4,6 +4,7 @@ - script: tools/run_tests/sanity/check_buildifier.sh - script: tools/run_tests/sanity/check_cache_mk.sh - script: tools/run_tests/sanity/check_deprecated_grpc++.py +- script: tools/run_tests/sanity/check_illegal_terms.sh - script: tools/run_tests/sanity/check_owners.sh - script: tools/run_tests/sanity/check_port_platform.py - script: tools/run_tests/sanity/check_qps_scenario_changes.py