blessing in disguise — A situation where an unfortunate and inauspicious event turns into good fortune.