Added setup_environment() call to stop() function

The stop function doesn't work properly as distributed, since all the settings
aren't initialized.  Adding a call to setup_environment at the top of stop() fixes
this.