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

lintian: r426 - in trunk: checks debian testset testset/maintainer-scripts/debian



Author: he
Date: 2005-07-08 20:51:05 +0200 (Fri, 08 Jul 2005)
New Revision: 426

Modified:
   trunk/checks/scripts
   trunk/checks/scripts.desc
   trunk/debian/changelog
   trunk/testset/maintainer-scripts/debian/postinst
   trunk/testset/tags.maintainer-scripts
Log:
checks/scripts:
  + [HE] Check for use of "." as a deprecated separator between user and
    group names in chown call. (Closes: #88340)


Modified: trunk/checks/scripts
===================================================================
--- trunk/checks/scripts	2005-06-27 09:10:02 UTC (rev 425)
+++ trunk/checks/scripts	2005-07-08 18:51:05 UTC (rev 426)
@@ -432,6 +432,10 @@
 	    if (m,(^|\s+)((/usr)?/bin/)?((b|d)?a|k|z|t?c)sh\s+-c\s*.+,) {
 		$within_another_shell = 1;
 	    }
+	    #Don't use chown foo.bar:
+	    if (m{(chown\s+[-_A-Za-z0-9]+\.[-_A-Za-z0-9]+)\s+}) {
+	    	tag "deprecated-chown-usage", "$file:$. \'$1\'";
+	    }
 	    # if cat_string is set, we are in a HERE document and need not
 	    # check for things
 	    if ($cat_string eq "" and $checkbashisms and !$within_another_shell) {

Modified: trunk/checks/scripts.desc
===================================================================
--- trunk/checks/scripts.desc	2005-06-27 09:10:02 UTC (rev 425)
+++ trunk/checks/scripts.desc	2005-07-08 18:51:05 UTC (rev 426)
@@ -639,3 +639,10 @@
  run by hand.
  .
  update-alternatives --remove should be called in the prerm instead.
+
+Tag: deprecated-chown-usage
+Type: warning
+Info: 'chown user.group' is called in one of the maintainer scripts.
+ This should be avoided, as the correct syntax is 'chown user:group'.
+ Using "." as a separator is still supported by the GNU tools, but it will
+ fail as soon as a system uses the "." in user or group names.

Modified: trunk/debian/changelog
===================================================================
--- trunk/debian/changelog	2005-06-27 09:10:02 UTC (rev 425)
+++ trunk/debian/changelog	2005-07-08 18:51:05 UTC (rev 426)
@@ -22,6 +22,8 @@
     + [HE] Check for use of adduser and update-inetd and warn if the package
       has no (pre-)dependency on adduser/netbase. Patch by Russ Allbery,
       thanks for the work. (Closes: #308569)
+    + [HE] Check for use of "." as a deprecated separator between user and
+      group names in chown call. (Closes: #88340)
 
  -- Marc 'HE' Brockschmidt <he@debian.org>  Tue, 21 Jun 2005 14:40:53 +0200
 

Modified: trunk/testset/maintainer-scripts/debian/postinst
===================================================================
--- trunk/testset/maintainer-scripts/debian/postinst	2005-06-27 09:10:02 UTC (rev 425)
+++ trunk/testset/maintainer-scripts/debian/postinst	2005-07-08 18:51:05 UTC (rev 426)
@@ -26,3 +26,6 @@
 echo Please use update-rc.d or invoke-rc.d to set up blah blah.
 
 wm-menu-config
+
+chown root.root /usr/share/doc/maintainer-scripts/changelog
+chown root:root /usr/share/doc/maintainer-scripts/changelog

Modified: trunk/testset/tags.maintainer-scripts
===================================================================
--- trunk/testset/tags.maintainer-scripts	2005-06-27 09:10:02 UTC (rev 425)
+++ trunk/testset/tags.maintainer-scripts	2005-07-08 18:51:05 UTC (rev 426)
@@ -13,6 +13,7 @@
 W: maintainer-scripts source: changelog-should-mention-qa
 W: maintainer-scripts source: qa-upload-has-incorrect-version-number 7-0.1
 W: maintainer-scripts: config-does-not-load-confmodule
+W: maintainer-scripts: deprecated-chown-usage postinst:30 'chown root.root'
 W: maintainer-scripts: maintainer-script-calls-deprecated-wm-menu-config postinst:28
 W: maintainer-scripts: missing-debconf-dependency
 W: maintainer-scripts: no-debconf-templates



Reply to: