@soren said in Socket having to close and reopen:
You close socket on server side then you must close it also on client side(it is closed already but..)
Question is what problem do you have with the code?
Is it working, if yes, do you ask if there is some better way?