In a shocking indication of a split between the White House and the Pentagon over the war in Afghanistan, Defense Secretary Robert Gates believes that the U.S. military will never leave the war-torn country.

During a dinner hosted by Secretary of State Hillary Clinton for Afghan President Hamid Karzai in May, Gates reminded the group that he still feels guilty for his role in the first President Bush's decision to pull out of Afghanistan after the Soviet withdrawal in 1989, according to Bob Woodward's new book, "Obama's Wars." And to express his commitment to not letting down the country again, he emphasized:

"We're not leaving Afghanistan prematurely," Gates finally said. "In fact, we're not ever leaving at all."

Woodward notes that the group was shocked by the blunt comment: "At least one stunned participant put down his fork. Another wrote it down, verbatim, in his notes."

The definitive statement seems to clash with President Obama's assertion that he does not want to leave the war to his successor. Though he has emphasized that the U.S. will stay in Afghanistan "until the job is done," he wants almost all the US troops out before the end of his first term in January 2013, leaving in place a small contingency force.

Yet Obama's public commitment to eventually leaving Afghanistan seems partly based on political calculation, reports Woodward. When questioned by Republican Senator Lindsay Graham about the July 2011 deadline to begin withdrawing troops, Obama tells him:

"Well, if you'd asked me that question, what I would say is, 'We're going to start leaving.' I have to say that. I can't let this be a war without end, and I can't lose the whole Democratic Party... And people at home don't want to hear we're going to be there for ten years."

White House Chief of Staff Rahm Emanuel privately refers to the war as "political flypaper" and the veteran of sharp-elbowed Chicago politics once got so frustrated with Karzai that he considered sending him "the equivalent of a dead fish with an imperial wrapping," writes Woodward. Emanuel's threat -- "Tell him we're going to put our own governors in if we have to" -- was ignored by the president during a meeting with military brass.

Gates, who is planning to leave his job before the 2012 presidential election, could be referring to that small contingency force with his comments. But his remarks do seem to highlight the differences between the military brass and the White House over Afghan strategy from the type of warfare to the size of the troop increase, as outlined in Woodward's book.

And it seems to further indicate the Pentagon's commitment to staying in Afghanistan. The commander of US troops in Afghanistan, Gen. David Petraeus, is quoted saying about the country:

"You have to recognize that I don't think you win this war. I think you keep fighting. You have to stay after it. This is the kind of fight we're in for the rest of our lives and probably our kids' lives."