It is narrated from Hazrat Samurah (may Allah be pleased with him) that the Prophet (peace and blessings of Allah be upon him) said: The seller and the buyer (the one who sells and the one who buys) have the option (to cancel the sale) as long as they do not separate from each other, and each of them can take what he is pleased with in the sale.
Hadith Referenceمسند احمد / أول مسند البصريين / 20252
Hadith Gradingحکم دارالسلام:صحيح لغيره، وهذا إسناد ضعيف، الحسن البصري مدلس، وقد عنعن