Re-fixed #11

The previous attempt would not overwrite the file.  It would just write
to the start of it.