Should be exception safe.