fixed file output