From: malaterre Date: Wed, 5 May 2004 02:13:02 +0000 (+0000) Subject: BUG: Write was clearly broken...can only blame myself X-Git-Tag: Version0.5.bp~189 X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=commitdiff_plain;ds=sidebyside;h=96f5b762d6acee38e841d461c020247d94c83e31;p=gdcm.git BUG: Write was clearly broken...can only blame myself --- diff --git a/src/gdcmFile.cxx b/src/gdcmFile.cxx index aa60bd76..1e7cf3d4 100644 --- a/src/gdcmFile.cxx +++ b/src/gdcmFile.cxx @@ -700,6 +700,7 @@ bool gdcmFile::WriteBase (std::string fileName, FileType type) { char * filePreamble; // writing Dicom File Preamble filePreamble=new char[128]; + memset(filePreamble,0,128); fwrite(filePreamble,128,1,fp1); fwrite("DICM",4,1,fp1); delete[] filePreamble;