summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorkamal@whence.com <kamal@whence.com@01de4be4-8c4a-0410-9132-4925637da917>2012-04-04 20:45:38 +0000
committerkamal@whence.com <kamal@whence.com@01de4be4-8c4a-0410-9132-4925637da917>2012-04-04 20:45:38 +0000
commit39b948e7c5a3e6e1af5a9f9d0a43de6e495144c7 (patch)
treec9edd60624094f77d893d917af90b268398aa237
parent3b3ae68ddb44aea1d2bf2ba452f8509e223f16d9 (diff)
downloaddistcc-39b948e7c5a3e6e1af5a9f9d0a43de6e495144c7.tar.gz
Fix for distcc issue 101 <http://code.google.com/p/distcc/issues/detail?id=101>:
pump should always report non-zero discrepancy count git-svn-id: http://distcc.googlecode.com/svn/trunk@762 01de4be4-8c4a-0410-9132-4925637da917
-rwxr-xr-xpump.in15
1 files changed, 9 insertions, 6 deletions
diff --git a/pump.in b/pump.in
index fb78194..9d10b04 100755
--- a/pump.in
+++ b/pump.in
@@ -341,14 +341,17 @@ ReportDiscrepancies() {
# failed remotely but succeeded locally.
num_discrepancies=`(cat $socket_dir/discrepancy_counter 2>/dev/null | wc -c \
|| echo 0)`
+ if [ $num_discrepancies -eq 0 ]; then
+ return 0
+ fi
+ echo "__________Warning: $num_discrepancies" \
+ 'pump-mode compilation(s) failed on server,' \
+ 'but succeeded locally.' 1>&2
if [ $num_discrepancies -ge $max_discrepancies_before_demotion ]; then
- echo "__________Warning: $num_discrepancies" \
- 'pump-mode compilation(s) failed on server,' \
- 'but succeeded locally.' 1>&2
- echo '__________Distcc-pump was demoted to plain mode.' \
- ' See the Distcc Discrepancy Symptoms section in the' \
- 'include_server(1) man page.' 1>&2
+ echo '__________Distcc-pump was demoted to plain mode.' 1>&2
fi
+ echo 'See the Distcc Discrepancy Symptoms section in the' \
+ 'include_server(1) man page.' 1>&2
}
ShutDown() {