From f20d23e4bf86a714fadba616e1ed65095f631b74 Mon Sep 17 00:00:00 2001 From: slewis Date: Sun, 19 May 2013 16:42:08 -0700 Subject: Fixed invalid filter syntax under some conditions --- .../osgi/services/distribution/BasicTopologyManagerImpl.java | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'compendium') diff --git a/compendium/bundles/org.eclipse.ecf.osgi.services.distribution/src/org/eclipse/ecf/internal/osgi/services/distribution/BasicTopologyManagerImpl.java b/compendium/bundles/org.eclipse.ecf.osgi.services.distribution/src/org/eclipse/ecf/internal/osgi/services/distribution/BasicTopologyManagerImpl.java index 117ffcec8..55e53d52b 100644 --- a/compendium/bundles/org.eclipse.ecf.osgi.services.distribution/src/org/eclipse/ecf/internal/osgi/services/distribution/BasicTopologyManagerImpl.java +++ b/compendium/bundles/org.eclipse.ecf.osgi.services.distribution/src/org/eclipse/ecf/internal/osgi/services/distribution/BasicTopologyManagerImpl.java @@ -38,14 +38,18 @@ public class BasicTopologyManagerImpl extends AbstractTopologyManager implements else { // If loopback not allowed, then we have our scope include // both !frameworkUUID same, and ONLY_ECF_SCOPE - StringBuffer elScope = new StringBuffer("("); //$NON-NLS-1$ + StringBuffer elScope = new StringBuffer(""); //$NON-NLS-1$ // filter so that local framework uuid is not the same as local // value - elScope.append("&("); //$NON-NLS-1$ - elScope.append("!(").append(org.osgi.service.remoteserviceadmin.RemoteConstants.ENDPOINT_FRAMEWORK_UUID).append("=").append(getFrameworkUUID()).append(")"); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ + elScope.append("(&(!(").append(org.osgi.service.remoteserviceadmin.RemoteConstants.ENDPOINT_FRAMEWORK_UUID).append("=").append(getFrameworkUUID()).append("))"); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ elScope.append(ONLY_ECF_SCOPE); elScope.append(")"); //$NON-NLS-1$ - elScope.append(")"); //$NON-NLS-1$ + try { + context.createFilter(elScope.toString()); + } catch (InvalidSyntaxException e) { + // TODO Auto-generated catch block + e.printStackTrace(); + } endpointListenerScope = elScope.toString(); } } -- cgit v1.2.3