From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 1851) id 736253860C35; Thu, 5 Nov 2020 11:34:12 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 736253860C35 Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: Martin Liska To: gcc-cvs@gcc.gnu.org Subject: [gcc(refs/users/marxin/heads/gcc-changelog-double-cherry-pick)] gcc-changelog: prevent double cherry-pick line X-Act-Checkin: gcc X-Git-Author: Martin Liska X-Git-Refname: refs/users/marxin/heads/gcc-changelog-double-cherry-pick X-Git-Oldrev: 7eb6c0ad2611e0802c3684196c9a7e94162f2c51 X-Git-Newrev: aa4ec769d9b423eedd02a0bfa8a8ba1b39e01870 Message-Id: <20201105113412.736253860C35@sourceware.org> Date: Thu, 5 Nov 2020 11:34:12 +0000 (GMT) X-BeenThere: gcc-cvs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-cvs mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 05 Nov 2020 11:34:12 -0000 https://gcc.gnu.org/g:aa4ec769d9b423eedd02a0bfa8a8ba1b39e01870 commit aa4ec769d9b423eedd02a0bfa8a8ba1b39e01870 Author: Martin Liska Date: Thu Nov 5 12:33:25 2020 +0100 gcc-changelog: prevent double cherry-pick line contrib/ChangeLog: * gcc-changelog/git_commit.py: Add new check. * gcc-changelog/test_email.py: Test it. * gcc-changelog/test_patches.txt: Add new patch. Diff: --- contrib/gcc-changelog/git_commit.py | 6 +++++- contrib/gcc-changelog/test_email.py | 4 ++++ contrib/gcc-changelog/test_patches.txt | 29 +++++++++++++++++++++++++++++ 3 files changed, 38 insertions(+), 1 deletion(-) diff --git a/contrib/gcc-changelog/git_commit.py b/contrib/gcc-changelog/git_commit.py index 0008865338b..80ae0b2a77d 100755 --- a/contrib/gcc-changelog/git_commit.py +++ b/contrib/gcc-changelog/git_commit.py @@ -423,7 +423,11 @@ class GitCommit: continue elif line.startswith(CHERRY_PICK_PREFIX): commit = line[len(CHERRY_PICK_PREFIX):].rstrip(')') - self.cherry_pick_commit = commit + if self.cherry_pick_commit: + self.errors.append(Error('multiple cherry pick lines', + line)) + else: + self.cherry_pick_commit = commit continue # ChangeLog name will be deduced later diff --git a/contrib/gcc-changelog/test_email.py b/contrib/gcc-changelog/test_email.py index df350a41228..e38c3e52158 100755 --- a/contrib/gcc-changelog/test_email.py +++ b/contrib/gcc-changelog/test_email.py @@ -362,6 +362,10 @@ class TestGccChangelog(unittest.TestCase): assert '\t2020-06-11 Martin Liska ' in entry assert '\t\t Jakub Jelinek ' in entry + def test_backport_double_cherry_pick(self): + email = self.from_patch_glob('double-cherry-pick.patch') + assert email.errors[0].message.startswith('multiple cherry pick lines') + def test_square_and_lt_gt(self): email = self.from_patch_glob('0001-Check-for-more-missing') assert not email.errors diff --git a/contrib/gcc-changelog/test_patches.txt b/contrib/gcc-changelog/test_patches.txt index bc9cc2e078e..37f49c851ec 100644 --- a/contrib/gcc-changelog/test_patches.txt +++ b/contrib/gcc-changelog/test_patches.txt @@ -3160,6 +3160,35 @@ index 823eb539993..4ec22162c12 100644 -- 2.27.0 +=== double-cherry-pick.patch === +From e1d68582022cfa2b1dc76646724b397ba2739439 Mon Sep 17 00:00:00 2001 +From: Martin Liska +Date: Thu, 11 Jun 2020 09:34:41 +0200 +Subject: [PATCH] asan: fix RTX emission for ilp32 + +gcc/ChangeLog: + + PR sanitizer/95634 + * asan.c (asan_emit_stack_protection): Fix emission for ilp32 + by using Pmode instead of ptr_mode. + +Co-Authored-By: Jakub Jelinek +(cherry picked from commit 8cff672cb9a132d3d3158c2edfc9a64b55292b80) +(cherry picked from commit 8cff672cb9a132d3d3158c2edfc9a64b55292b80) +--- + gcc/asan.c | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/gcc/asan.c b/gcc/asan.c +index 823eb539993..4ec22162c12 100644 +--- a/gcc/asan.c ++++ b/gcc/asan.c +@@ -1 +1,2 @@ + ++ +-- +2.27.0 + === 0001-Check-for-more-missing-math-decls-on-vxworks.patch === From 0edfc1fd22405ee8e946101e44cd8edc0ee12047 Mon Sep 17 00:00:00 2001 From: Douglas B Rupp