Fix in removing unprocessed frames.