when remote endpoint has an error, just close it