Romans 3:23 states that all have sinned, and even a great servant such as Abraham would not be an exception. In fact, Abraham twice lied to kings to save his skin by stating that Sarah was his sister.
God forgave these sins of weakness, not committed out of hostility or rebellion against the will of God, but rather of temptation, and this augmented by the willing participation of an otherwise faithful wife.