app/testpmd: fix division by zero on socket memory dump