Some small changes to make sure that things work if the video returns a smaller number of frames than it has previously reported that it has.