(Devarim 21:12) "And it shall be towards evening that he shall wash himself with water": This teaches us that a seminal emission exempts a zivah (seminal) discharge within the same twenty-four hour period (from the requirement of cleansing, the verse implying that whatever intervenes, he will be clean in the evening.)
Washing Toward Evening and the Laws of Ritual Purity
Sifrei Devarim 256:1