Fixed ping calculation.