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

[lintian] 01/01: cmd/lintian: Replace two die() calls with fatal_error



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

nthykier pushed a commit to branch master
in repository lintian.

commit 33975cbf26eb97eb658c1336a66cc14f1b2fa12b
Author: Niels Thykier <niels@thykier.net>
Date:   Sun Oct 1 17:15:20 2017 +0000

    cmd/lintian: Replace two die() calls with fatal_error
    
    Signed-off-by: Niels Thykier <niels@thykier.net>
---
 commands/lintian.pm | 10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)

diff --git a/commands/lintian.pm b/commands/lintian.pm
index 398caec..b920e1d 100755
--- a/commands/lintian.pm
+++ b/commands/lintian.pm
@@ -1268,7 +1268,8 @@ sub parse_config_file {
             if (m/^\s*([-a-z]+)\s*=\s*(.*\S)\s*$/o){
                 my ($var, $val) = ($1, $2);
                 my $ref = $cfghash{$var};
-                die "Unknown configuration variable $var at line: ${.}.\n"
+                fatal_error(
+                    "Unknown configuration variable $var at line: ${.}.")
                   unless $ref;
                 if (exists $conf_opt{$var}){
                     print STDERR
@@ -1408,9 +1409,10 @@ sub configure_output {
     #    it before the config check.
     $opt{'color'} = 'auto' unless defined($opt{'color'});
     if ($opt{'color'} and $opt{'color'} !~ /^(?:never|always|auto|html)$/) {
-        die join(q{ },
-            'The color value must be one of',
-            "\"never\", \"always\", \"auto\" or \"html\"\n");
+        fatal_error(
+            join(q{ },
+                'The color value must be one of',
+                'never", "always", "auto" or "html"'));
     }
     if ($opt{'tag-display-limit'} eq 'auto') {
         if (-t STDOUT) {

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/lintian/lintian.git


Reply to: