Abu Dawud Book 36, Hadith Number 5218.
Narated By Anas ibn Malik : The Apostle of Allah (PBUH) came out, and on seeing a high-domed building, he said: What is it?
His companions replied to him: It belongs to so and so, one of the Ansar.
He said: he said nothing but kept the matter in mind. When its owner came and gave him a greeting among the people, he turned away from him. When he had done this several times, the man realised that he was the cause of the anger and the rebuff.
So he complained about it to his companions, saying: I swear by Allah that I cannot understand the Apostle of Allah (PBUH).
They said: He went out and saw your domed building. So the man returned to it and demolished it, levelling it to the ground. One day the Apostle of Allah (PBUH) came out and did not see it.
He asked: What has happened to the domed building?
They replied: Its owner complained to us about your rebuff, and when we informed him about it, he demolished it.
He said: Every building is a misfortune for its owner, except what cannot, except what cannot, meaning except that which is essential.