pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/pkgtools/pkglint/files - Fixed a bug that had been int...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/c984a2bee177
branches:  trunk
changeset: 503826:c984a2bee177
user:      rillig <rillig%pkgsrc.org@localhost>
date:      Thu Dec 01 01:19:30 2005 +0000

description:
- Fixed a bug that had been introduced in revision 1.391, preventing
  warnings that LIST+=FOO=${FOO} should rather be LIST+=FOO=${FOO:Q}.
  The cause was that I had added a capturing group in a regular
  expression that also contained a back reference (\2). Adjusted the
  back reference to \3. (This is the only place in pkglint where such
  back references are used, so I don't have much experience with them.)

diffstat:

 pkgtools/pkglint/files/pkglint.pl |  4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diffs (21 lines):

diff -r 6a364deeb421 -r c984a2bee177 pkgtools/pkglint/files/pkglint.pl
--- a/pkgtools/pkglint/files/pkglint.pl Thu Dec 01 00:27:56 2005 +0000
+++ b/pkgtools/pkglint/files/pkglint.pl Thu Dec 01 01:19:30 2005 +0000
@@ -11,7 +11,7 @@
 # Freely redistributable.  Absolutely no warranty.
 #
 # From Id: portlint.pl,v 1.64 1998/02/28 02:34:05 itojun Exp
-# $NetBSD: pkglint.pl,v 1.395 2005/11/30 20:16:15 rillig Exp $
+# $NetBSD: pkglint.pl,v 1.396 2005/12/01 01:19:30 rillig Exp $
 #
 # This version contains lots of changes necessary for NetBSD packages
 # done by:
@@ -1966,7 +1966,7 @@
                }
 
        } elsif ($type eq "ShellWord") {
-               if ($value =~ qr"^([\w_]+)=(([\"']?)\$\{([\w_]+)\}\2)$") {
+               if ($value =~ qr"^([\w_]+)=(([\"']?)\$\{([\w_]+)\}\3)$") {
                        my ($key, $vexpr, undef, $vname) = ($1, $2, $3, $4);
                        my $mod = ($vname =~ regex_gnu_configure_volatile_vars) ? ":M*:Q" : ":Q";
                        my $fixed_vexpr = "\${${vname}${mod}}";



Home | Main Index | Thread Index | Old Index