add system slices on local hosts only -
authorThierry Parmentelat <thierry.parmentelat@sophia.inria.fr>
Thu, 23 Nov 2006 19:43:34 +0000 (19:43 +0000)
committerThierry Parmentelat <thierry.parmentelat@sophia.inria.fr>
Thu, 23 Nov 2006 19:43:34 +0000 (19:43 +0000)
though I'm not sure I understand what sense it makes for a plc
to answer GetSlivers for a non-local node

PLC/Methods/GetSlivers.py

index 1c9746c..ace99c5 100644 (file)
@@ -148,8 +148,8 @@ class GetSlivers(Method):
 
             # If not a foreign node, add all of our default system
             # slices to it.
-            # XXX if not node['peer_id']:
-            slice_ids.update(system_slice_ids)
+            if node['peer_id'] is not None:
+               slice_ids.update(system_slice_ids)
 
             slivers = []
             for slice in map(lambda id: all_slices[id], slice_ids.keys()):