Check that frame is ok before copying in lastFrame.