Keep a self reference for the lifetime of a thread

Signed-off-by: Rick Taylor <rick@tropicalstormsoftware.com>