Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthew Khouzam2012-07-19 19:12:58 +0000
committerMatthew Khouzam2012-07-20 18:00:57 +0000
commitac6b3ffacebdf64ddc43eb583a3367cbc464bd56 (patch)
tree4df48022844139d9199fe9ab6493e550a95168ad
parent6b03d1e37a77dc856b458fb088ebf715bb14fb99 (diff)
downloadorg.eclipse.linuxtools-ac6b3ffacebdf64ddc43eb583a3367cbc464bd56.tar.gz
org.eclipse.linuxtools-ac6b3ffacebdf64ddc43eb583a3367cbc464bd56.tar.xz
org.eclipse.linuxtools-ac6b3ffacebdf64ddc43eb583a3367cbc464bd56.zip
Fix negative timestamp seek bug.
Change-Id: Ic0e77da05419261ff082103d0e232723b51a3be1 Signed-off-by: Matthew Khouzam <matthew.khouzam@ericsson.com> Reviewed-on: https://git.eclipse.org/r/6871 Reviewed-by: Patrick Tasse <patrick.tasse@gmail.com> IP-Clean: Patrick Tasse <patrick.tasse@gmail.com> Tested-by: Patrick Tasse <patrick.tasse@gmail.com> Reviewed-by: Mathieu Denis <mathieu.denis55@gmail.com>
-rw-r--r--lttng/org.eclipse.linuxtools.tmf.core/src/org/eclipse/linuxtools/tmf/core/ctfadaptor/CtfIterator.java6
1 files changed, 3 insertions, 3 deletions
diff --git a/lttng/org.eclipse.linuxtools.tmf.core/src/org/eclipse/linuxtools/tmf/core/ctfadaptor/CtfIterator.java b/lttng/org.eclipse.linuxtools.tmf.core/src/org/eclipse/linuxtools/tmf/core/ctfadaptor/CtfIterator.java
index c18f0b5fed..39ffbf8343 100644
--- a/lttng/org.eclipse.linuxtools.tmf.core/src/org/eclipse/linuxtools/tmf/core/ctfadaptor/CtfIterator.java
+++ b/lttng/org.eclipse.linuxtools.tmf.core/src/org/eclipse/linuxtools/tmf/core/ctfadaptor/CtfIterator.java
@@ -17,10 +17,10 @@ import org.eclipse.linuxtools.tmf.core.trace.ITmfLocation;
/**
* The CTF trace reader iterator.
- *
+ *
* It doesn't reserve a file handle, so many iterators can be used without worries
* of I/O errors or resource exhaustion.
- *
+ *
* @version 1.0
* @author Matthew Khouzam
*/
@@ -118,7 +118,7 @@ public class CtfIterator extends CTFTraceReader implements ITmfContext, Comparab
final long offsetTimestamp = timestamp
- this.getTrace().getOffset();
if (offsetTimestamp < 0) {
- ret = super.seek(timestamp);
+ ret = super.seek(0L);
} else {
ret = super.seek(offsetTimestamp);
}

Back to the top