]> xenbits.xensource.com Git - qemu-xen.git/commitdiff
checkpatch: check Signed-off-by in --mailback mode
authorPaolo Bonzini <pbonzini@redhat.com>
Thu, 29 Nov 2018 08:31:41 +0000 (09:31 +0100)
committerPaolo Bonzini <pbonzini@redhat.com>
Fri, 11 Jan 2019 12:57:23 +0000 (13:57 +0100)
Pull the test before the anticipated exits from the process sub.

Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
scripts/checkpatch.pl

index 66eb68e85a0e28f92c9edd5db64bfe097a00f8bb..42e782a65642607d63bdc08e3f9bf5c36527bf62 100755 (executable)
@@ -2864,6 +2864,10 @@ sub process {
                }
        }
 
+       if ($is_patch && $chk_signoff && $signoff == 0) {
+               ERROR("Missing Signed-off-by: line(s)\n");
+       }
+
        # If we have no input at all, then there is nothing to report on
        # so just keep quiet.
        if ($#rawlines == -1) {
@@ -2885,9 +2889,6 @@ sub process {
        if (!$is_patch) {
                ERROR("Does not appear to be a unified-diff format patch\n");
        }
-       if ($is_patch && $chk_signoff && $signoff == 0) {
-               ERROR("Missing Signed-off-by: line(s)\n");
-       }
 
        print report_dump();
        if ($summary && !($clean == 1 && $quiet == 1)) {