[tor-commits] [tor/master] Extract code to summarize protocol versions into new function