In the wee hours of Sunday morning, climate negotiators pulled out an agreement on climate change after two days of last-ditch efforts. The decision puts world leaders on a path to a negotiating a legal agreement beginning in 2015 and managed to avoid a total disaster, but still leaves a number of questions open.

In some ways, the agreement is better than many had expected heading into Durban. The US, China, India and a few other countries had been reluctant to commit to a timeline for a legal agreement, while the European Union and small island nations were insistent that one be laid out. Over the course of two days, various versions of an agreement outlining a process to create a Protocol, legal framework, or a "legal outcome" were debated furiously among delegates. India emerged as the strongest critic, arguing that as a developing country it should not be held to the same standard as industrialized nations. But at around 3:30 a.m. on Sunday morning, there was a breakthrough.

Earlier, South African Minister and COP president Maite Nkoana-Mashabane pleaded with the parties not to leave Durban with nothing completed. "I think we all realize they are not perfect, but we should not let the perfect become the enemy of the good and the possible," she said.

In the end, it came down to a single turn of phrase: changing "legal outcome" in the earlier draft to "an agreed outcome with legal force under the convention applicable to all parties." That was enough to win the consent of Indian negotiator Jayanthi Natarajan, who earlier had worried that her country was "being made the scapegoats" of the meeting for not consenting to the agreement. But she could not, she said, "sign away the rights of 1.2 billion people and many other people in the developing world" by agreeing to something that could limit their ability to grow their economy.

Her impassioned speech, however, was followed by equally moving remarks from Karl Hood, the negotiator from Grenada and representative for the Alliance of Small Island States, who are the most immediately imperiled by climate change. "This little island is where I get my dignity from," said Hood. "I shouldn't be transported somewhere else by the whims and fancy of others who want to develop."

Of course, the change still leaves the agreement, termed the "Durban Platform for Enhanced Action," somewhat vague. Even if negotiations on a new legal agreement are set to begin under in 2015, it's not clear when they'd conclude. It also reaffirms the goal of holding global warming to no more than 2 degrees Celsius (3.6 Fahrenheit), notes with "grave concern" that the pledges listed won't meet that goal, and launches a "work plan" to consider improving those targets. But countries are still continuing pledges that put the world on a path toward 4 degrees C warming (7 degrees F).

While it's notable that the US, China, and India agreed to creating a legal pathway, there was still concern from developing countries that too much burden had been shifted to them. China expressed concern that the developed nations were not doing enough. "It is not what is said by countries it is what is done by countries, and many are not realizing their commitments," said Xie Zhenhua, China's lead negotiators. "We've been talking about this for 20 years, they're still not being acted upon … We want to see your real actions."

Nor was there a clear decision on the existing Kyoto Protocol, the first commitment period of the treaty ends in Dec. 2012. The text calls for an extension until either 2017 or 2020, but leaves a decision on the date for next year. And while it moves the creation of a Green Climate Fund to help poor nations both cut emissions and adapt to climate change forward, it does not include any decisions about how to put money in the fund. Several countries, including Russia and Nicaragua, lodged complaints about the last-minute decisions and that their concerns with the text had not been addressed.

"Over the past 17 years, they've kicked the big issues down the road," said Samantha Smith, leader of the global climate and energy initiative at the World Wildlife Fund International. "The hardest issues are still on the table."

Kate Sheppard was a staff reporter in Mother Jones' Washington bureau from 2009 to 2013. She is now a senior reporter and the energy and environment editor at The Huffington Post. She can be reached by email at kate (dot) sheppard (at) huffingtonpost (dot) com and you can follow her on Twitter @kate_sheppard.