Previous 15994 Revisions Next

r3042 Friday 15th August, 2008 at 14:21:39 UTC by Firewave
Use sizeof in memset() calls
[src/mess/machine]atarifdc.c gb.c x68k_hdc.c
[src/mess/tools/imgtool/modules]ti99.c

src/mess/tools/imgtool/modules/ti99.c
r3041r3042
52935293
52945294
52955295   /* now clear every other physrecs, including the FDIR record */
5296   memset(empty_sec, 0, 256);
5296   memset(empty_sec, 0, sizeof(empty_sec));
52975297
52985298   for (i=1; i<totphysrecs; i++)
52995299      if (write_absolute_physrec(& l1_img, i, empty_sec))
src/mess/machine/gb.c
r3041r3042
313313   gb_sound_w(machine, 0x14,0x77);
314314
315315   sgb_window_mask = 0;
316   memset( sgb_pal_map, 0, 20*18 );
317   memset( sgb_atf_data, 0, 4050 );
316   memset( sgb_pal_map, 0, sizeof(sgb_pal_map) );
317   memset( sgb_atf_data, 0, sizeof(sgb_atf_data) );
318318
319319   /* HACKS for Donkey Kong Land 2 + 3.
320320      For some reason that I haven't figured out, they store the tile
src/mess/machine/x68k_hdc.c
r3041r3042
6363   int ret;
6464   unsigned char sectordata[256];  // empty block data
6565
66   memset(sectordata,0,256);
66   memset(sectordata,0,sizeof(sectordata));
6767   for(x=0;x<0x013c98;x++)  // 0x13c98 = number of blocks on a 20MB HD
6868   {
6969      ret = image_fwrite(image,sectordata,256);
src/mess/machine/atarifdc.c
r3041r3042
138138   {
139139      int sector;
140140      char buff[256];
141      memset(buff, 0, 256);
141      memset(buff, 0, sizeof(buff));
142142      /* default to 720 sectors */
143143      for( sector = 0; sector < 720; sector++ )
144144         image_fwrite(image, buff, 256);

Previous 15994 Revisions Next


© 1998-2018 The MESS Team