In a 5-minute match a player makes an illegal move leaving his king in a check position. This usually gives the victory to the opponent, if he sees it and captures the king. Otherwise, if the opponent doesn't claim the illegal move within 2 moves, the game just continues as if nothing happened.
But what happens, if the opponent runs out of time just before he captures the king? Is it a time win, since the opponent didn't claim the illegal move within his time limit? Or does the illegal move automatically lose, once it is noticed?
If the illegal move automatically loses, that raises the following theoretical question: What if nobody immediately sees the illegal move, and the game is considered to be lost on time. But after a while the opponent notices the illegal move and claims it. Is there a time limit to that, and how is it enforced after the clocks have stopped ticking?
And lastly, would the decision be any different, if the match was longer/shorter?