ffmpeg will only assign the correct keyframe flag to the video pkt, which is the one used later to be written to the final file.