Fixed type of thread handle close callback.