Sahih Bukhari
Afflictions and the End of the World
Volume: 009 / Book Number: 088 / Hadith Number: 177
Narrated Ibn 'Abbas:
The Prophet said, "Whoever notices something which he dislikes done by his ruler, then he should be patient, for whoever becomes separate from the company of the Muslims even for a span and then dies, he will die as those who died in the Pre-lslamic period of Ignorance (as rebellious sinners). (Fateh-Al-Bari page 112, Vol. 16)