Fix two memory leaks in vtkNIFTIWriter.