diff --git a/similar/main/multi.c b/similar/main/multi.c index b6a7e2f06..a8ac1c0d4 100644 --- a/similar/main/multi.c +++ b/similar/main/multi.c @@ -5181,7 +5181,7 @@ void init_hoard_data() } GameSounds[Num_sound_files+i].length = len; - GameSounds[Num_sound_files+i].data = d_malloc(len); + MALLOC(GameSounds[Num_sound_files+i].data, ubyte, len); PHYSFS_read(ifile,GameSounds[Num_sound_files+i].data,1,len); if (GameArg.SndDigiSampleRate == SAMPLE_RATE_11K) { @@ -5253,7 +5253,7 @@ void save_hoard_data(void) ifile = PHYSFS_openRead(sounds[i]); Assert(ifile != NULL); size = PHYSFS_fileLength(ifile); - buf = d_malloc(size); + MALLOC(buf, ubyte, size); PHYSFS_read(ifile, buf, size, 1); PHYSFS_writeULE32(ofile, size); PHYSFS_write(ofile, buf, size, 1);