Fixed socket_write return