When talking to a gdb-remote server that didn't support the newer thread info packets, we noticed that lldb would hit a breakpoint in target, but then continue on without stopping. This was because the only indication of why you stopped in this scenario was the initial "T05thread:01;" packet. Unfortunately, lldb read the stop reasons from the stop packet and created the new thread & set its stop reason BEFORE calling UpdateThreadListIfNeeded. So when you finally got around to calling UpdateThreadListIfNeeded, we would notice that the ThreadList StopID was out of date, wipe the stop reasons, and then update. Normally some other thread info packet would tell us the stop reason again, and we we'd get back on track. But if they weren't supported, we'd be left thinking that the process had stopped for no reason, and auto-continue it.
The main part of the patch just adjusts the call to UpdateThreadListIfNeeded so it happens before we try to set StopInfo's.
I also added a test that captures this failure.