gzclose on bad pointer == glibc errors like these: https://travis-ci.org/SciLifeLab/facs/builds/5288215
Merge pull request #9 from brainstorm/master

Fixed glibc fault because gzclose bad pointer