You are creating the thread on the stack inside the loop, so the object (and the thread behind it) gets killed before it has a chance to do anything. And you might be experiencing a crash if you never reach the second iteration of the loop.
You are creating the thread on the stack inside the loop, so the object (and the thread behind it) gets killed before it has a chance to do anything. And you might be experiencing a crash if you never reach the second iteration of the loop.
Bookmarks