Code cleanup & bug fix (again)

Saving did not use the proper filename with special characters (åäö,
etc)