(New York) -- Legendary investor Warren Buffett warned Congressional leaders Saturday night of "the biggest financial meltdown in American history" if they did not act to secure the financial system.

Buffett, by telephone, was consulted by lawmakers who were in marathon talks on Capitol Hill to forge a deal on the administration's $700 billion economic bailout plan, according to two sources.

One lawmaker in the negotiations said that the participants called Warren Buffett to get his help in gauging potential market reaction.

Congressional leaders said shortly after midnight Saturday that they had reached a tentative deal. Members of both parties and Treasury Secretary Henry Paulson were aiming to craft final legislation by Sunday evening -- in time for the start of financial markets around the world.

Assuring markets, especially credit markets that lend to businesses and consumers as well as between banks, is seen as a vital part of getting a deal done quickly.

The marathon negotiations on Saturday culminated several chaotic - and at times politically divisive - days on Capitol Hill as lawmakers and administration officials tried to quickly find common ground on a complicated proposal.

Earlier in the week, Buffett also warned that the financial crisis is "everybody's problem," not just Wall Street's. The potential collapse of financial institutions would cause industry to grind to a halt, he told CNBC Wednesday, and could have "gummed up the economy."

On Tuesday Buffett's company Berkshire Hathaway (BRK.A) invested $5 billion in Goldman Sachs (GS, Fortune 500). The cash gives one of the last-remaining Wall Street investment banks a much-need boost as credit has tightened. Buffett's move also helped shore up confidence in financial stocks.

Buffett, whom Forbes magazine has placed at No. 2 on its 2008 list of richest Americans, is worth an estimated $50 billion. In 2006, he pledged to donate most of his fortune to charity.

Calls to Berkshire Hathaway seeking comment from Buffett were not immediately returned.

America's Money Crisis