devtools: fix name check with mbox files
PATCH 1/1 devtools: fix name check with mbox files
When passing a patch downloaded as mbox, the mail headers were being scanned which resulted in mailing list and other unrelated mail addresses being checked against the contributors list.
Filter them by focusing on the mail body (separated from the headers with the first empty line).
--- devtools/checkpatches.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
devtools/checkpatches.sh +1 -1
@@ -254,7 +254,7 @@ check_names() { # <patch> old_IFS=$IFS IFS=' ' - for contributor in $(sed -rn '1,/^--- / {s/.*: (.*<.*@.*>)/\1/p}' $1); do + for contributor in $(sed -rn '/^$/,/^--- / {s/.*: (.*<.*@.*>)/\1/p}' $1); do ! grep -qE "^$contributor($| <)" .mailmap || continue name=${contributor%% <*} if grep -q "^$name <" .mailmap; then
Signature · 1 line
2.38.1
Quoted 4 lines · David Marchand
When passing a patch downloaded as mbox, the mail headers were being scanned which resulted in mailing list and other unrelated mail addresses being checked against the contributors list.
Quoted 8 lines
Filter them by focusing on the mail body (separated from the headers with the first empty line).
Fixes e83d41f0694d ("mailmap: add list of contributors")Signed-off-by David Marchand <[email protected]>---
Thomas Monjalon
Applied29/11/2022 22:33, Tyler Retzlaff:
Quoted 8 lines · David Marchand
Quoted 7 lines
When passing a patch downloaded as mbox, the mail headers were being scanned which resulted in mailing list and other unrelated mail addresses being checked against the contributors list.
Filter them by focusing on the mail body (separated from the headers with the first empty line).
Quoted 6 lines
Quoted 4 lines
Fixes e83d41f0694d ("mailmap: add list of contributors")Signed-off-by David Marchand <[email protected]>Acked-by Tyler Retzlaff <[email protected]>
Applied, thanks.