Fix bug on exit

See the bug report (https://github.com/Floobits/flootty/issues/16) for more info.