Shimei cursed David in (ESV) 2 Samuel 16:
Well, the Hebrew was ambiguous. Septuagint translated it as "will look upon my affliction".
NIV:
In David's head, God could have told Shimei to curse David even though it was wrong for Shimei to do it.11 David said to Abishai and to all his servants, “Behold, my own son seeks my life; how much more now may this Benjaminite! Leave him alone, and let him curse, for the LORD has told him to. 12 It may be that the LORD will look on the wrong done to me, and that the LORD will repay me with good for his cursing today.”
Well, the Hebrew was ambiguous. Septuagint translated it as "will look upon my affliction".
NIV:
It may be that the Lord will look upon my misery and restore to me his covenant blessing instead of his curse today.