[debhelper-devel] [debhelper] 09/09: Dh_Lib.pm: Better errors when a exec-config fails

Niels Thykier nthykier at moszumanska.debian.org
Wed Jun 15 20:29:17 UTC 2016


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

nthykier pushed a commit to branch master
in repository debhelper.

commit d5c0bf324ee4587b53990b2fc0abd85b89dbc775
Author: Niels Thykier <niels at thykier.net>
Date:   Wed Jun 15 18:39:20 2016 +0000

    Dh_Lib.pm: Better errors when a exec-config fails
    
    Signed-off-by: Niels Thykier <niels at thykier.net>
---
 Debian/Debhelper/Dh_Lib.pm | 9 ++++++++-
 debian/changelog           | 3 +++
 2 files changed, 11 insertions(+), 1 deletion(-)

diff --git a/Debian/Debhelper/Dh_Lib.pm b/Debian/Debhelper/Dh_Lib.pm
index 213e7cc..f8fae26 100644
--- a/Debian/Debhelper/Dh_Lib.pm
+++ b/Debian/Debhelper/Dh_Lib.pm
@@ -802,7 +802,14 @@ sub filedoublearray {
 		push @ret, [@line];
 	}
 
-	close DH_FARRAY_IN || error("problem reading $file: $!");
+	if (!close(DH_FARRAY_IN)) {
+		if ($x) {
+			error("Error closing fd/process for $file: $!") if $!;
+			error_exitcode("$file (executable config)");
+		} else {
+			error("problem reading $file: $!");
+		}
+	}
 	
 	return @ret;
 }
diff --git a/debian/changelog b/debian/changelog
index 1cb62b6..db04957 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -46,6 +46,9 @@ debhelper (9.20160403+unreleased) UNRELEASED; urgency=medium
     the package.
   * dh_strip: Cache file(1) output to avoid calling file(1)
     twice on all ELF binaries in the package.
+  * Dh_Lib.pm: Add better error messages when a debhelper program
+    fails due to an executable config file not terminating with
+    success.  (Closes: #818933)
 
  -- Niels Thykier <niels at thykier.net>  Sat, 09 Apr 2016 09:20:32 +0000
 

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




More information about the debhelper-devel mailing list