mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-07-30 20:35:38 +02:00
Fallback on the first thread when no selection is specified.
This commit is contained in:
parent
5598211d05
commit
9387b687f5
1 changed files with 5 additions and 0 deletions
|
@ -244,6 +244,11 @@ public class Target implements ICDITarget {
|
|||
cthreads = new Thread[]{new Thread(this, 0)};
|
||||
}
|
||||
currentThreadId = info.getCurrentThread();
|
||||
//FIX: When attaching there is no thread selected
|
||||
// We will choose the first one as a workaround.
|
||||
if (currentThreadId == 0 && cthreads.length > 0) {
|
||||
currentThreadId = cthreads[0].getId();
|
||||
}
|
||||
} catch (MIException e) {
|
||||
// Do not throw anything in this case.
|
||||
//throw new CDIException(e.getMessage());
|
||||
|
|
Loading…
Add table
Reference in a new issue