Fix handle close for FileDumper and GzFileDumper