Worst case scenario? The Founders, long believing that the Solids of the galaxy cannot be trusted, would see the Federation saving them from certain extinction, in spite of their war of aggression against the UFP -- and demanding nothing in return. It might not end the war, but it would almost certainly undermine the ideological basis for the Founders' xenophobia. It might lead neutral Alpha Quadrant powers to side with the Federation, and it would plant the seeds of change in the Dominion body politic. And in a best-case scenario? The Founders would call off the war from gratitude.
It would be worth the risk.
No, the worst case scenario is that the Founders take the cure and continue the war unabated. They'd lost Cardassia, but a kamikaze-type offensive by the remaining Dominion forces was a real possibility.
Besides, you're assuming the Founders are rational, with their xenophobia merely a rational response to past persecution. It's not rational (considering they'd not been persecuted for centuries but still retained it as motivation and justification for conquering the galaxy) and no single goodwill gesture could possibly undermine millennia of xenophobia.
And rather than gaining support from neutral powers in the AQ, it's more likely that the AQ powers would turn on the Feds for acting unilaterally. You don't think the Klingons and Romulans would object to their primary ally handing over their best leverage to the enemy? And even the Ferengi would ask why the Feds would be insane enough to give something so valuable away for no gain.