aboutsummaryrefslogtreecommitdiffstats
path: root/tools/checklicenses.py
diff options
context:
space:
mode:
authorGerald Combs <gerald@wireshark.org>2020-06-07 12:12:12 -0700
committerAnders Broman <a.broman58@gmail.com>2020-06-08 05:06:10 +0000
commit43b5c63aea95ce7a3346ca1dbb09a49aba333bfe (patch)
treed88c54c575bbdf899f57fa2354e1307d7a36b020 /tools/checklicenses.py
parent668161f8ddd016b0de3870462657de4b141752e0 (diff)
Tools: Use better terminology.
"Allowed" is a perfectly fine, non-biased word for designating things that are allowed. Change-Id: Ia1e0642a073210f0475fba3d437eac654ec36cb5 Reviewed-on: https://code.wireshark.org/review/37397 Petri-Dish: Anders Broman <a.broman58@gmail.com> Tested-by: Petri Dish Buildbot Reviewed-by: Anders Broman <a.broman58@gmail.com>
Diffstat (limited to 'tools/checklicenses.py')
-rwxr-xr-xtools/checklicenses.py18
1 files changed, 9 insertions, 9 deletions
diff --git a/tools/checklicenses.py b/tools/checklicenses.py
index b52c94627b..dda74ed3ab 100755
--- a/tools/checklicenses.py
+++ b/tools/checklicenses.py
@@ -18,8 +18,8 @@ def PrintUsage():
to the script file. This will be correct given the normal location
of the script in "<root>/tools".
- --ignore-suppressions Ignores path-specific license whitelist. Useful when
- trying to remove a suppression/whitelist entry.
+ --ignore-suppressions Ignores path-specific allowed license. Useful when
+ trying to remove a suppression/allowed entry.
tocheck Specifies the directory, relative to root, to check. This defaults
to "." so it checks everything.
@@ -29,7 +29,7 @@ Examples:
python checklicenses.py --root ~/chromium/src third_party""")
-WHITELISTED_LICENSES = [
+ALLOWED_LICENSES = [
'BSD',
'BSD (2 clause)',
'BSD (2 clause) GPL (v2 or later)',
@@ -49,7 +49,7 @@ WHITELISTED_LICENSES = [
]
-PATH_SPECIFIC_WHITELISTED_LICENSES = {
+PATH_SPECIFIC_ALLOWED_LICENSES = {
'caputils/airpcap.h': [
'BSD-3-Clause',
],
@@ -213,20 +213,20 @@ def check_licenses(options, args):
continue
# Support files which provide a choice between licenses.
- if any(item in WHITELISTED_LICENSES for item in license.split(';')):
+ if any(item in ALLOWED_LICENSES for item in license.split(';')):
continue
if not options.ignore_suppressions:
found_path_specific = False
- for prefix in PATH_SPECIFIC_WHITELISTED_LICENSES:
+ for prefix in PATH_SPECIFIC_ALLOWED_LICENSES:
if (filename.startswith(prefix) and
- license in PATH_SPECIFIC_WHITELISTED_LICENSES[prefix]):
+ license in PATH_SPECIFIC_ALLOWED_LICENSES[prefix]):
found_path_specific = True
break
if found_path_specific:
continue
- reason = "'%s' has non-whitelisted license '%s'" % (filename, license)
+ reason = "License '%s' for '%s' is not allowed." % (license, filename)
success = False
print(reason)
exit_status = 1
@@ -253,7 +253,7 @@ def main():
option_parser.add_option('--ignore-suppressions',
action='store_true',
default=False,
- help='Ignore path-specific license whitelist.')
+ help='Ignore path-specific allowed license.')
options, args = option_parser.parse_args()
return check_licenses(options, args)