Fixed counter formatting & 64-bit warning