mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-04-23 06:32:10 +02:00
Bug 412547 - Selection is lost when stepping over "pthread_create" for
gdbserver sessions Change-Id: Ide875ba350dfd3e17579519360999b82c572c355 Reviewed-on: https://git.eclipse.org/r/14415 Reviewed-by: Mikhail Khodjaiants <mikhailkhod@googlemail.com> IP-Clean: Mikhail Khodjaiants <mikhailkhod@googlemail.com> Tested-by: Mikhail Khodjaiants <mikhailkhod@googlemail.com>
This commit is contained in:
parent
6873bc9001
commit
6891ce8e0f
1 changed files with 14 additions and 0 deletions
|
@ -11,6 +11,8 @@
|
|||
*******************************************************************************/
|
||||
package org.eclipse.cdt.dsf.mi.service.command.output;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.Comparator;
|
||||
|
||||
|
||||
/**
|
||||
|
@ -143,6 +145,18 @@ public class MIThreadInfoInfo extends MIInfo {
|
|||
for (int i = 0; i < values.length; i++) {
|
||||
threadList[i] = MIThread.parse((MITuple) values[i]);
|
||||
}
|
||||
Arrays.sort(threadList, new Comparator<MIThread>() {
|
||||
|
||||
@Override
|
||||
public int compare(MIThread o1, MIThread o2) {
|
||||
try {
|
||||
return Integer.parseInt(o1.getThreadId()) - Integer.parseInt(o2.getThreadId());
|
||||
}
|
||||
catch(NumberFormatException e) {
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
});
|
||||
return threadList;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue