Previous 199869 Revisions Next

r21149 Sunday 17th February, 2013 at 16:36:18 UTC by Angelo Salese
Small fix for size allocation
[src/emu/machine]stvcd.c
[src/emu/video]stvvdp2.c

trunk/src/emu/video/stvvdp2.c
r21148r21149
17211721
17221722   #define STV_VDP2_LWTA1U (m_vdp2_regs[0x0dc/2])
17231723
1724   #define STV_VDP2_W1LWE  ((STV_VDP2_LWTA0U & 0x8000) >> 15)
1724   #define STV_VDP2_W1LWE  ((STV_VDP2_LWTA1U & 0x8000) >> 15)
17251725
17261726
17271727/* 1800de - Line Window Table Address (W1)
trunk/src/emu/machine/stvcd.c
r21148r21149
10151015            if (partitions[bufnum].numblks < sectnum)
10161016            {
10171017               printf("CD: buffer is not full %08x %08x\n",partitions[bufnum].numblks,sectnum);
1018               /* TODO: why this is happening? */
10191018               cr_standard_return(CD_STAT_REJECT);
10201019               hirqreg |= (CMOK|EHST);
10211020               return;
r21148r21149
10631062            for (int i = xfersectpos; i < xfersectpos+xfersectnum; i++)
10641063            {
10651064               transpart->blocks[i] = cd_alloc_block(&transpart->bnum[i]);
1065               if(transpart->size == -1)
1066                  transpart->size = 0;
10661067               transpart->size += transpart->blocks[i]->size;
10671068               transpart->numblks++;
10681069            }
r21148r21149
10911092            {
10921093               // allocate the dst blocks
10931094               partitions[dst_filter].blocks[i] = cd_alloc_block(&partitions[dst_filter].bnum[i]);
1095               if(partitions[dst_filter].size == -1)
1096                  partitions[dst_filter].size = 0;
10941097               partitions[dst_filter].size += partitions[dst_filter].blocks[i]->size;
10951098               partitions[dst_filter].numblks++;
10961099
r21148r21149
23602363
23612364   // update the status of the partition
23622365   if (filterprt->size == -1)
2363   {
23642366      filterprt->size = 0;
2365   }
2367
23662368   filterprt->size += filterprt->blocks[filterprt->numblks]->size;
23672369   filterprt->numblks++;
23682370

Previous 199869 Revisions Next


© 1997-2024 The MAME Team