Improved file save handling

This fixes the issue submitted by @errge https://github.com/LonnyGomes/hexcurse/issues/9