[tor-commits] [tor/master] config.c: extract validate, check-transition, and set into a function