[libparse-debianchangelog-perl] 45/52: Allow '.' and '+' in distribution name

Intrigeri intrigeri at moszumanska.debian.org
Sun May 24 12:37:32 UTC 2015


This is an automated email from the git hooks/post-receive script.

intrigeri pushed a commit to branch master
in repository libparse-debianchangelog-perl.

commit a9e67bcb417e9b0b9b73a4b148f072ab623fd641
Author: John Wright <john.wright at hp.com>
Date:   Mon Apr 4 17:51:47 2011 +0200

    Allow '.' and '+' in distribution name
---
 Changes                      | 2 ++
 lib/Parse/DebianChangelog.pm | 2 +-
 t/examples/countme           | 2 +-
 3 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/Changes b/Changes
index e8715a3..0b2e3a3 100644
--- a/Changes
+++ b/Changes
@@ -4,6 +4,8 @@ Parse-DebianChangelog (1.2.0) unstable; urgency=low
     - Improve readability of regexes by using named captures
     - Don't use $& or $` (Closes: #515018)
     - Don't use "English" just for $.
+    - Allow '.' and '+' in distribution names. Patch by John Wright.
+      (Closes: #565238)
   * ChangesFilters:
     - Fix conversion of <http://something/> (Closes: #603341)
     - Allow to omit # before closed bug numbers (Closes: 446798 ;)
diff --git a/lib/Parse/DebianChangelog.pm b/lib/Parse/DebianChangelog.pm
index 2f37a7e..8f78f8d 100644
--- a/lib/Parse/DebianChangelog.pm
+++ b/lib/Parse/DebianChangelog.pm
@@ -313,7 +313,7 @@ sub parse {
     while (<$fh>) {
 	s/\s*\n$//;
 #	printf(STDERR "%-39.39s %-39.39s\n",$expect,$_);
-	if (m/^(?<Source>\w[-+0-9a-z.]*) \((?<Version>[^\(\) \t]+)\)(?<Distribution>(?:\s+[-0-9a-z]+)+)\;\s*(?<kv>.*)$/i) {
+	if (m/^(?<Source>\w[-+0-9a-z.]*) \((?<Version>[^\(\) \t]+)\)(?<Distribution>(?:\s+[-+0-9a-z.]+)+)\;\s*(?<kv>.*)$/i) {
 	    unless ($expect eq 'first heading'
 		    || $expect eq 'next heading or eof') {
 		$entry->{ERROR} = [ $file, $.,
diff --git a/t/examples/countme b/t/examples/countme
index 166b72f..fe0e2d6 100644
--- a/t/examples/countme
+++ b/t/examples/countme
@@ -1,4 +1,4 @@
-countme (2:2.0-1) unstable; urgency=low
+countme (2:2.0-1) some.other+fancy-dist; urgency=low
 
   * Final
 

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-perl/packages/libparse-debianchangelog-perl.git



More information about the Pkg-perl-cvs-commits mailing list