Hi folks,

 any objections to commit the attached patch for a longstanding gmetad problem 
into 3.0.X? I already put it into trunk a few days ago. The fix was developed 
by Timothy on top of 3.0.6 and is in production use. Please vote.

Cheers
Martin
------------------------------------------------------
Martin Knoblauch
email: k n o b i AT knobisoft DOT de
www:   http://www.knobisoft.de

Index: server.c
===================================================================
--- server.c	(revision 1102)
+++ server.c	(working copy)
@@ -285,8 +285,18 @@
          return 0;
 
       case SUMMARY:
-         return source_summary((Source_t*) node, client);
 
+/* use the mutex to avoid reporting incomplete sums -twitham (bug#76) */
+	 if (((Source_t*)node)->sum_finished)
+	   pthread_mutex_lock(((Source_t*)node)->sum_finished);
+
+	 int i = source_summary((Source_t*) node, client);
+
+	 if (((Source_t*)node)->sum_finished)
+	   pthread_mutex_unlock(((Source_t*)node)->sum_finished);
+
+         return i;
+
       default:
          break;
       }
-------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace
_______________________________________________
Ganglia-developers mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ganglia-developers

Reply via email to