DESCRIPTION

Ctf: Callsite bug fix when position is negative (binarySearch)

Change-Id: Id1fdb06c717299f7b0fa8ad0576485d35003ce2b
Signed-off-by: Kelsie Blackwell xxx@xxx.xxx


COMMENTS

author: Kelsie Blackwell
date: 2013-05-21 19:27:44.000000000

Uploaded patch set 4.

-------------------------------------
author: Brenden Conley
date: 2013-05-21 19:27:49.000000000

Patch Set 4:

Build Started https://hudson.eclipse.org/sandbox/job/linuxtools/2374/ 

-------------------------------------
author: Brenden Conley
date: 2013-05-21 19:50:26.000000000

Patch Set 4: Verified

Build Successful 

https://hudson.eclipse.org/sandbox/job/linuxtools/2374/ : SUCCESS

-------------------------------------
author: Braxton Mccarthy
date: 2013-05-22 00:31:42.000000000

Patch Set 4: I would prefer that you didn't submit this

(1 inline comment)

Looking good now, but I have one small question, see comment. Perhaps this should be commented to explain what is going on?

Also, it would be nice to have a small unit test for this. I don't think we have easily-accessible traces with multiple callsites, but just a synthetic array of callsites going through this code path to confirm that it does what we want it to do.

Line:940, lttng/org.eclipse.linuxtools.ctf.core/src/org/eclipse/linuxtools/ctf/core/trace/CTFTrace.java -> .binarySearch() could return pos == .size(), which would mean "this element would be placed last". In this case you will not pick the last element (size() - 1), but the first one, with .getFirst().

Is this intended?

-------------------------------------
