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

Bug#323098: lintian: while [[ is a bashism, [[:space:]] & co. are POSIX



Package: lintian
Version: 1.23.11
Severity: normal

The test introduced as a result of 296233 is a little overzealous,
catching valid POSIX regular expressions.  The patch below fixes it,
hopefully correctly.

--- checks/scripts.old  2005-08-14 13:28:30.000000000 -0400
+++ checks/scripts      2005-08-14 13:35:13.000000000 -0400
@@ -461,7 +461,7 @@
                  '(?:^|\s+)(trap\s+["\']?.*["\']?\s+.*[1-9])', # trap with sign
al numbers
                  '(?:^|\s+)(local)\s',        # local scoping of variables
                  '(\&>)',                     # cshism
-                 '(\[\[)',                    # alternative test command
+                 '(\[\[[^:(alnum|alpha|blank|cntrl|digit|graph|lower|print|punc
t|space|upper|xdigit)])', # alternative test command, but not POSIX regex
                );
 
                for my $re (@bashism_regexs) {


I think I've got them all there - check
http://www.opengroup.org/onlinepubs/009695399/toc.htm section 9.3.5.6 to
double check.

-- System Information:
Debian Release: testing/unstable
  APT prefers unstable
  APT policy: (500, 'unstable')
Architecture: amd64 (x86_64)
Shell:  /bin/sh linked to /bin/bash
Kernel: Linux 2.6.11-9-amd64-k8
Locale: LANG=C, LC_CTYPE=en_US.ISO-8859-15 (charmap=ISO-8859-15) (ignored: LC_ALL set to en_US.ISO-8859-15)

Versions of packages lintian depends on:
ii  binutils                   2.16.1-2      The GNU assembler, linker and bina
ii  diffstat                   1.39-1        produces graph of changes introduc
ii  file                       4.12-1        Determines file type using "magic"
ii  gettext                    0.14.5-2      GNU Internationalization utilities
ii  intltool-debian            0.30+20040213 Help i18n of RFC822 compliant conf
ii  libparse-debianchangelog-p 0.6-1         parse Debian changelogs and output
ii  man-db                     2.4.3-1       The on-line manual pager
ii  perl [libdigest-md5-perl]  5.8.7-4       Larry Wall's Practical Extraction 

lintian recommends no packages.

-- no debconf information



Reply to: