Restore original precision after writing a double

Found by coverity
Merge branch 'master' of github.com:wesnoth/wesnoth-old
Make the initially selected modificiation determine the button text
Assert that a pointer isn't null

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