Strip off trailing \n in submissions. Fixes #411.
Merge pull request #418 from kytrinyx/sanitize-eof

Strip off trailing \n in submissions. Fixes #411.