From patchwork Wed Feb 10 10:13:58 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: [2/3] UBUNTU: git-ubuntu-log -- tighten up Bug: NNNN matching Date: Wed, 10 Feb 2010 00:13:58 -0000 From: Andy Whitcroft X-Patchwork-Id: 45004 Message-Id: <1265796839-15820-3-git-send-email-apw@canonical.com> To: kernel-team@lists.ubuntu.com We are currently miss-matching lines such as the following as Bug: number links: BUG: unable to handle kernel NULL pointer dereference at (null) Ensure that lines only contain numbers, hashes (#), commas (,) and spaces. Signed-off-by: Andy Whitcroft --- debian/scripts/misc/git-ubuntu-log | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/debian/scripts/misc/git-ubuntu-log b/debian/scripts/misc/git-ubuntu-log index b7ca943..abcfa12 100755 --- a/debian/scripts/misc/git-ubuntu-log +++ b/debian/scripts/misc/git-ubuntu-log @@ -189,8 +189,8 @@ sub changelog_input { } while () { $ignore = 1 if /^ *Ignore: yes/i; - if (/^ *Bug: *(#|)(.*)/i) { - foreach $k (split('(,|)*\s*#', $2)) { + if (/^ *Bug: *(#|)([0-9#,\s]*)\s*$/i) { + foreach $k (split('(,|\s)\s*(#|)', $2)) { $bugz{$k} = 1 if (($k ne '') and ($k =~ /[0-9]+/)); } }