better ping handling