qpid-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From acon...@apache.org
Subject svn commit: r940573 - /qpid/trunk/qpid/python/qpid/brokertest.py
Date Mon, 03 May 2010 19:10:23 GMT
Author: aconway
Date: Mon May  3 19:10:23 2010
New Revision: 940573

URL: http://svn.apache.org/viewvc?rev=940573&view=rev
Log:
Fix race condition in store+cluster tests.

Modified:
    qpid/trunk/qpid/python/qpid/brokertest.py

Modified: qpid/trunk/qpid/python/qpid/brokertest.py
URL: http://svn.apache.org/viewvc/qpid/trunk/qpid/python/qpid/brokertest.py?rev=940573&r1=940572&r2=940573&view=diff
==============================================================================
--- qpid/trunk/qpid/python/qpid/brokertest.py (original)
+++ qpid/trunk/qpid/python/qpid/brokertest.py Mon May  3 19:10:23 2010
@@ -388,6 +388,7 @@ class Broker(Popen):
     def store_state(self):
         uuids = open(os.path.join(self.datadir, "cluster", "store.status")).readlines()
         null_uuid="00000000-0000-0000-0000-000000000000\n"
+        if len(uuids) < 2: return "unknown" # we looked while the file was being updated.
         if uuids[0] == null_uuid: return "empty"
         if uuids[1] == null_uuid: return "dirty"
         return "clean"



---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project:      http://qpid.apache.org
Use/Interact: mailto:commits-subscribe@qpid.apache.org


Mime
View raw message