Fix a copy-paste error

Found by coverity
Fix a copy-paste error

Found by coverity
Factor out two nearly-identical format_time_summary functions
Remove an unused assignment

Found by coverity
Merge branch 'master' of github.com:wesnoth/wesnoth-old