From: Rabbi Moshe Sofer
To: Rabbi Mordechai
A Jew forgot to sell his flour before Pesach and sold it to a non-Jew after midday on Erev Pesach, then sold it again after Pesach. The Chasam Sofer rules that the monetary proceeds are permitted based on the principle of ein tofeis demeihen, combined with multiple grounds for leniency.
Source: Shu"t Chasam Sofer OC §114