Added support for thread/pipe idiom

Creates a background thread with an inproc socket pair connected between the caller of thread::fork and the handler supplied to thread::fork(), which is run in a separate thread.