Fixed threading bug.