Catch errors when trying to close the connection thread
Catch errors when trying to close the connection thread

Contributes to #82

bq/Ultimaker-Cura,ad1217/Cura,fxtentacle/Cura,senttech/Cura,ad1217/Cura,totalretribution/Cura,Curahelper/Cura,markwal/Cura,DeskboxBrazil/Cura,lo0ol/Ultimaker-Cura,hmflash/Cura,fxtentacle/Cura,hmflash/Cura,Curahelper/Cura,ynotstartups/Wanhao,senttech/Cura,fieldOfView/Cura,ynotstartups/Wanhao,DeskboxBrazil/Cura,markwal/Cura,lo0ol/Ultimaker-Cura,bq/Ultimaker-Cura,fieldOfView/Cura,totalretribution/Cura