diff --git a/stella/src/emucore/CartCV.cxx b/stella/src/emucore/CartCV.cxx index 2eafd1acb..58882c88c 100644 --- a/stella/src/emucore/CartCV.cxx +++ b/stella/src/emucore/CartCV.cxx @@ -13,7 +13,7 @@ // See the file "license" for information on usage and redistribution of // this file, and for a DISCLAIMER OF ALL WARRANTIES. // -// $Id: CartCV.cxx,v 1.1 2002-01-18 15:58:46 estolberg Exp $ +// $Id: CartCV.cxx,v 1.2 2002-03-18 14:40:07 gunfight Exp $ //============================================================================ #include @@ -24,7 +24,9 @@ // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - CartridgeCV::CartridgeCV(const uInt8* image, uInt32 size) { - if(size == 2048) + uInt32 addr; + + if(size == 2048) { // Copy the ROM image into my buffer for(uInt32 addr = 0; addr < 2048; ++addr) @@ -45,13 +47,13 @@ CartridgeCV::CartridgeCV(const uInt8* image, uInt32 size) // Usefull for MagiCard program listings // Copy the ROM image into my buffer - for(uInt32 addr = 0; addr < 2048; ++addr) + for(addr = 0; addr < 2048; ++addr) { myImage[addr] = image[addr + 2048]; } // Copy the RAM image into my buffer - for(uInt32 addr = 0; addr < 1024; ++addr) + for(addr = 0; addr < 1024; ++addr) { myRAM[addr] = image[addr]; } diff --git a/stella/src/emucore/CartDPC.cxx b/stella/src/emucore/CartDPC.cxx index cc1468d94..a0b6e60a1 100644 --- a/stella/src/emucore/CartDPC.cxx +++ b/stella/src/emucore/CartDPC.cxx @@ -13,7 +13,7 @@ // See the file "license" for information on usage and redistribution of // this file, and for a DISCLAIMER OF ALL WARRANTIES. // -// $Id: CartDPC.cxx,v 1.1 2001-12-30 18:43:30 bwmott Exp $ +// $Id: CartDPC.cxx,v 1.2 2002-03-18 14:40:07 gunfight Exp $ //============================================================================ #include @@ -23,14 +23,16 @@ // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - CartridgeDPC::CartridgeDPC(const uInt8* image, uInt32 size) { - // Copy the program ROM image into my buffer - for(uInt32 addr = 0; addr < 8192; ++addr) + uInt32 addr; + + // Copy the program ROM image into my buffer + for(addr = 0; addr < 8192; ++addr) { myProgramImage[addr] = image[addr]; } // Copy the display ROM image into my buffer - for(uInt32 addr = 0; addr < 2048; ++addr) + for(addr = 0; addr < 2048; ++addr) { myDisplayImage[addr] = image[8192 + addr]; }