Rfc6810 bis

pull request for reviewing code
add goto out and you can remove the else branch