Added in IOExcept and Socket

This is my thoughts on how to the try and catch code plus I added in the
sockets.