ping functions fix