TCP client dies

Please see the forum tricks and tips for how to format code! :slight_smile: