tmf: Insert null values for newly-created attributes
authorAlexandre Montplaisir <alexmonthy@voxpopuli.im>
Fri, 26 Apr 2013 17:52:37 +0000 (13:52 -0400)
committerAlexandre Montplaisir <alexmonthy@voxpopuli.im>
Fri, 26 Apr 2013 20:17:21 +0000 (16:17 -0400)
commit25e4374955ed2df65126d5d5d4d377ea26858128
treeddb2ad832db4ba1f5f1f826626f905ca0099a72c
parent61dfcb35fb9d4e1acd211a73bf07e8dd8b01ba97
tmf: Insert null values for newly-created attributes

Instead of requiring every state provider to explicitely insert
a value when creating a new attribute, we can have the attribute
tree do it for them. Then, if the provider wants to set it to
something else, it's just changing a variable in memory.

This fixes a potential problem in the LTTng-kernel state provider,
where a value could get reset to null if no new attributes are
created between two sched_switch events.

Change-Id: I600125f560f0362671379848c572359be2f74cc7
Signed-off-by: Alexandre Montplaisir <alexmonthy@voxpopuli.im>
Reviewed-on: https://git.eclipse.org/r/12249
Reviewed-by: Genevieve Bastien <gbastien+lttng@versatic.net>
Tested-by: Hudson CI
Reviewed-by: Patrick Tasse <patrick.tasse@gmail.com>
IP-Clean: Patrick Tasse <patrick.tasse@gmail.com>
org.eclipse.linuxtools.lttng2.kernel.core/src/org/eclipse/linuxtools/internal/lttng2/kernel/core/stateprovider/CtfKernelStateInput.java
org.eclipse.linuxtools.tmf.core/src/org/eclipse/linuxtools/internal/tmf/core/statesystem/AttributeTree.java
This page took 0.027623 seconds and 5 git commands to generate.