عن أبي هريرة قال: قال رسول الله صلى الله عليه وسلم: «إذا وجد أحدكم في بطنه شيئًا، فأشكل عليه أخرج منه شيء أم لا، فلا يَخرجنَّ من المسجد حتى يسمع صوتًا، أو يجد ريحًا».
[صحيح] - [رواه مسلم]
Abu Hurayrah (may Allah be pleased with him) reported: The Messenger of Allah (may Allah’s peace and blessings be upon him) said: "If one of you feels something in his stomach and doubts whether he released some wind or not, he should not leave the mosque unless he hears a sound or smells an odor."
Sahih/Authentic. - [Muslim]
The Prophet (may Allah’s peace and blessings be upon him) explained that if a person feels some disturbance in his stomach, as wind moves therein, and he is not sure whether something has come out of him, he should not leave the place of prayer to renew his ablution, because a certain thing is not abrogated by a doubtful one. He is certain about his purification in the first place and doubtful whether it has been broken or not. So, he should leave the prayer unless he hears a sound or smells an odor. That's he becomes certain that his ablution has been broken by hearing the sound of passing wind or smelling its odor. It is not necessary to both hear the sound and smell the odor - one of them is enough. However, if a person, who is not obsessive, knows for sure that wind has passed, without hearing a sound smelling an odor, his ablution gets invalidated, for the Hadīth aims at the existence of certainty. The Prophet (may Allah’s peace and blessings be upon him) made this statement regarding one who is doubtful about the passing of wind from him, and it does not mean that ablution is not broken without hearing a sound or smelling an odor. The Hadīth provides an important rule: A certain thing is not abrogated by a doubtful one.