fix time measurement