[lintian] 01/02: c/scripts: Check syntax of sh maintscripts with sh
This is an automated email from the git hooks/post-receive script.
nthykier pushed a commit to branch master
in repository lintian.
commit 9535b23d72a1c037974f0706a5e4796f15534ec4
Author: Niels Thykier <niels@thykier.net>
Date: Mon Nov 9 19:51:20 2015 +0100
c/scripts: Check syntax of sh maintscripts with sh
In the "good old days", sh was always a symlink to bash. This is no
longer the case and we now need to check with "sh" in some cases.
Signed-off-by: Niels Thykier <niels@thykier.net>
---
checks/scripts.pm | 2 +-
debian/changelog | 4 ++++
2 files changed, 5 insertions(+), 1 deletion(-)
diff --git a/checks/scripts.pm b/checks/scripts.pm
index 9a8dde2..8313aa7 100644
--- a/checks/scripts.pm
+++ b/checks/scripts.pm
@@ -594,7 +594,7 @@ sub run {
if ($shellscript) {
$checkbashisms = $base eq 'sh' ? 1 : 0;
if ($base eq 'sh' or $base eq 'bash') {
- if (check_script_syntax('/bin/bash', $path)) {
+ if (check_script_syntax("/bin/${base}", $path)) {
tag 'maintainer-shell-script-fails-syntax-check', $file;
}
}
diff --git a/debian/changelog b/debian/changelog
index 5845e6f..f234682 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -14,6 +14,10 @@ lintian (2.5.39) UNRELEASED; urgency=medium
+ [JW] Fix typo.
* checks/files.pm:
+ [BR] Whitelist pbuilder for dir-or-file-in-build-tree.
+ * checks/scripts.pm:
+ + [NT] Check the syntax of maintainter scripts with "sh" when
+ the script is declared with "#!/bin/sh". Thanks to Ron Lee
+ for spotting this.
* checks/shared-libs.pm:
+ [ADB, NT] Fix false-positive instance of the tag
postrm-should-call-ldconfig when the package is using the
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/lintian/lintian.git
Reply to: