Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBernd Hufmann2013-11-18 14:37:41 -0500
committerBernd Hufmann2013-11-22 16:57:40 -0500
commit7785b0c72fbb261f1598914948981d3852ecf39a (patch)
treef001f78894f85adad49b641c86fdfc400d7e08fb
parent594993668f350a335dfbd24cd33e89b46d0862de (diff)
downloadorg.eclipse.linuxtools-7785b0c72fbb261f1598914948981d3852ecf39a.tar.gz
org.eclipse.linuxtools-7785b0c72fbb261f1598914948981d3852ecf39a.tar.xz
org.eclipse.linuxtools-7785b0c72fbb261f1598914948981d3852ecf39a.zip
tmf: Deregister traces used for validation only from signal manager
Bug 421860 Change-Id: I885ab62960a8cfc8af50591e52c239d0ca9c2479 Signed-off-by: Bernd Hufmann <Bernd.Hufmann@ericsson.com> Reviewed-on: https://git.eclipse.org/r/18521 Reviewed-by: Alexandre Montplaisir <alexmonthy@voxpopuli.im> IP-Clean: Alexandre Montplaisir <alexmonthy@voxpopuli.im> Tested-by: Alexandre Montplaisir <alexmonthy@voxpopuli.im> Tested-by: Hudson CI
-rw-r--r--lttng/org.eclipse.linuxtools.tmf.ui/src/org/eclipse/linuxtools/tmf/ui/project/model/TmfTraceType.java13
1 files changed, 11 insertions, 2 deletions
diff --git a/lttng/org.eclipse.linuxtools.tmf.ui/src/org/eclipse/linuxtools/tmf/ui/project/model/TmfTraceType.java b/lttng/org.eclipse.linuxtools.tmf.ui/src/org/eclipse/linuxtools/tmf/ui/project/model/TmfTraceType.java
index 5ab1d47b70..c3dfb185d4 100644
--- a/lttng/org.eclipse.linuxtools.tmf.ui/src/org/eclipse/linuxtools/tmf/ui/project/model/TmfTraceType.java
+++ b/lttng/org.eclipse.linuxtools.tmf.ui/src/org/eclipse/linuxtools/tmf/ui/project/model/TmfTraceType.java
@@ -39,6 +39,7 @@ import org.eclipse.linuxtools.internal.tmf.ui.parsers.custom.CustomXmlTrace;
import org.eclipse.linuxtools.internal.tmf.ui.parsers.custom.CustomXmlTraceDefinition;
import org.eclipse.linuxtools.internal.tmf.ui.project.model.TmfTraceImportException;
import org.eclipse.linuxtools.tmf.core.TmfCommonConstants;
+import org.eclipse.linuxtools.tmf.core.signal.TmfSignalManager;
import org.eclipse.linuxtools.tmf.core.trace.ITmfTrace;
import org.eclipse.swt.SWT;
import org.eclipse.swt.events.SelectionEvent;
@@ -308,15 +309,21 @@ public final class TmfTraceType {
// add the custom trace types
for (CustomTxtTraceDefinition def : CustomTxtTraceDefinition.loadAll()) {
String traceTypeId = CustomTxtTrace.class.getCanonicalName() + SEPARATOR + def.definitionName;
- TraceTypeHelper tt = new TraceTypeHelper(traceTypeId, CUSTOM_TXT_CATEGORY, def.definitionName, new CustomTxtTrace(def));
+ ITmfTrace trace = new CustomTxtTrace(def);
+ TraceTypeHelper tt = new TraceTypeHelper(traceTypeId, CUSTOM_TXT_CATEGORY, def.definitionName, trace);
fTraceTypes.put(traceTypeId, tt);
traceTypes.add(traceTypeId);
+ // Deregister trace as signal handler because it is only used for validation
+ TmfSignalManager.deregister(trace);
}
for (CustomXmlTraceDefinition def : CustomXmlTraceDefinition.loadAll()) {
String traceTypeId = CustomXmlTrace.class.getCanonicalName() + SEPARATOR + def.definitionName;
- TraceTypeHelper tt = new TraceTypeHelper(traceTypeId, CUSTOM_XML_CATEGORY, def.definitionName, new CustomXmlTrace(def));
+ ITmfTrace trace = new CustomXmlTrace(def);
+ TraceTypeHelper tt = new TraceTypeHelper(traceTypeId, CUSTOM_XML_CATEGORY, def.definitionName, trace);
fTraceTypes.put(traceTypeId, tt);
traceTypes.add(traceTypeId);
+ // Deregister trace as signal handler because it is only used for validation
+ TmfSignalManager.deregister(trace);
}
return traceTypes;
}
@@ -356,6 +363,8 @@ public final class TmfTraceType {
ITmfTrace trace = null;
try {
trace = (ITmfTrace) ce.createExecutableExtension(TmfTraceType.TRACE_TYPE_ATTR);
+ // Deregister trace as signal handler because it is only used for validation
+ TmfSignalManager.deregister(trace);
} catch (CoreException e) {
}
TraceTypeHelper tt = new TraceTypeHelper(typeId, category, attribute, trace);

Back to the top