Fix chunk count

When a file only has two chunks, the count was wrong and the header was
missing
Merge pull request #46 from PVince81/fix-chunk-count

Fix chunk count