Sahih Muslim
The Book of Prayers (Kitab Al-Salat)
Book Number: 004 / Hadith Number: 1142
Ibn 'Umar reported: The Messenuer of Allah (may peace be upon him) said: He who eats of this (offensive) plant must not approach our mosque, till its odour dies: (plant signifies) garlic.