Fixed generation of headers section of files