Canada's men's water polo team didn't qualify for the Olympics but there's still a slim chance they will compete at the Summer Games.
Constantine Kudaba scored twice late as Canada beat the Former Yugoslav Republic of Macedonia 11-10 to finish fifth at the Olympic qualifying tournament Sunday.
The result means Canada will compete in London if any one of the qualifiers — Greece, Montenegro, Romania or Spain — cannot attend.
Canada squandered a 4-0 lead after the first quarter, then fell 9-8 after Macedonia scored three unanswered goals in the fourth.
Macedona took a 10-9 lead with 1:25 remaining, but Kudaba scored 20 seconds later and then added the winning goal with 20 seconds remaining in the game.
Justin Boyd, Luka Gasic and Jared McElroy also had two goals for Canada (5-2-0), while Devon Diggle, John Conway and Oliver Vikalo added a goal apiece.
Miroslav Randjikj led Macedonia (3-5-0) with four goals, Marko Martinic scored twice and Mateo Cuk, Ivan Basara, Dimitar Dimovski and Danijel Benikj had one each.
"A little frustrated," said Boyd. "It's great that we finished with a win, it's just the way we did it is a little frustrating. ... I've got to say a big thanks to Con (Kudaba) for burying those two late ones to bail us out there."
Canada was hoping to qualify for the Olympics for only the second time in team history after making it to the 2008 Summer Games in Beijing.
But the team fell 10-6 to Greece in the quarter-final Friday to miss out on a qualification at the 11-team tournament.
"We're just more excited for the next tournament," said Boyd. "Each game is closer and closer against teams that used to beat us pretty handily. Now it's just going to be an exciting summer regardless of not going to London."
Canada had also appeared in three other Summer Olympics without going through the qualification process, filling in for teams that dropped out in 1972 and 1984 and as the host team in Montreal in 1976.