id,summary,reporter,owner,description,type,status,priority,milestone,component,version,severity,resolution,keywords,cc 2629,MrSID SerializeMetadataRec uses bad int sizes on 64-bit compile,jburgess777,Even Rouault,"I ran Valgrind on some software reading a MrSid format file using GDAL and it reported that MrSIDDataset::SerializeMetadataRec() was reading memory beyond the size that had been allocated. {{{ ==12016== Invalid read of size 8 ==12016== at 0xD6D7054: MrSIDDataset::SerializeMetadataRec(LizardTech::LTIMetadataRecord const*) (mrsiddataset.cpp:962) ... ==12016== Invalid read of size 8 ==12016== at 0xD6D715C: MrSIDDataset::SerializeMetadataRec(LizardTech::LTIMetadataRecord const*) (mrsiddataset.cpp:959) }}} This error occurs because the current code casts the 32 bit data to a 'long *' which is a 64-bit type on x86-64. Changing these to GInt32/GUInt32 fixes it.",defect,closed,normal,1.5.4,GDAL_Raster,unspecified,normal,fixed,mrsid,