LoginSignup
0
1

More than 5 years have passed since last update.

c++ builder > TThread:WaitFor()を使うときの注意 > FreeOnTerminateをfalseにしておく

Last updated at Posted at 2015-06-11
動作環境
c++ Builder XE4

TThread:にはWaitFor()がある (http://www.gesource.jp/weblog/?p=562)。

TThread:WaitFor()を使って、threadの終了を待っていたのだが、WaitFor()にたどり着かない問題があった。

http://www.borlandtalk.com/image-vp94655.html
によると

I seem to remember that FreeOnTerminate must be false if you are going to use WaitFor() as otherwise the thread's memory can get deleted before you return
from Terminate() and you can get intermittent AVs.

0
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
1