That's actually just a function of how the flashcard system works - in order to keep flashcard sessions from taking even longer to start up than they already do, it doesn't actually check to make sure that each card has a valid headword / pronunciation / definition (or linked dictionary entry) until the card actually comes up in the session. So it's likely that those last two cards are getting skipped over because they're incomplete. This also explains why the card count decreases in other test modes, Pleco lowers the count when it skips over a card.