How is the main problem solved in the hunger games?

katniss and peeta are the only two left and they both agree to eat the poison berries to kill them selves to show the game makers that they are not the boss of them, but right before they do it the game makers declare a game victory for both peeta and katniss.