Fixed a bug that made dumping the data crash because of the presence of
illegal characters in the filename.