And then rename the temporary file when closed. This protects users data in case Ocarina gets killed. Implements issue #31: Make file writes seem atomic Signed-off-by: Anna Schumaker <Anna@OcarinaProject.net>