fix error when socket suddenly ends - show warning