Fixed bug with zero file size