Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthew Khouzam2012-07-19 19:12:58 +0000
committerMatthew Khouzam2012-07-20 18:04:39 +0000
commit10a12763d19f99031c08cd9e3eabb980137ab066 (patch)
treeb9d4fc7848d060147bbf05ef8dc33785fd91b5b3
parent0ae26a96a1079bced2ac8f29403c04fa04c7017b (diff)
downloadorg.eclipse.linuxtools-10a12763d19f99031c08cd9e3eabb980137ab066.tar.gz
org.eclipse.linuxtools-10a12763d19f99031c08cd9e3eabb980137ab066.tar.xz
org.eclipse.linuxtools-10a12763d19f99031c08cd9e3eabb980137ab066.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