From 0ef2be669e468cfecd4879eee0c7dbf91b952880 Mon Sep 17 00:00:00 2001 From: Ian Jackson Date: Fri, 19 Mar 2010 11:38:44 +0000 Subject: [PATCH] Debugging of modack.approved pipe failures --- stump/bin/acceptFromMod.pl | 3 ++- stump/bin/processApproved | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/stump/bin/acceptFromMod.pl b/stump/bin/acceptFromMod.pl index 3e408f1..fde6b3d 100755 --- a/stump/bin/acceptFromMod.pl +++ b/stump/bin/acceptFromMod.pl @@ -130,6 +130,7 @@ while( <> ) { } print STDERR "Comment is: $comment\n" if( $comment ); +print STDERR "Signal handling for SIGPIPE: $SIG{PIPE}.\n"; $ENV{'EXPLANATION'} = $comment; @@ -144,7 +145,7 @@ open( COMMAND, "| $command" ) || &processError( "$command failed" ); # "\n======================================= MODERATOR'S COMMENT: \n" . # $comment; # } -close( COMMAND ) or die "$? $!"; +close( COMMAND ) or die "$command $? $!"; &processError( "No action specified" ) if( $done ne "yes" ); diff --git a/stump/bin/processApproved b/stump/bin/processApproved index 615d0c1..1b2f176 100755 --- a/stump/bin/processApproved +++ b/stump/bin/processApproved @@ -1,6 +1,6 @@ #!/bin/bash -set -e +set -ex set -o pipefail NEWSBIN=/var/lib/newsbin; export NEWSBIN -- 2.30.2