diff --git a/src/debugger/CartDebug.cxx b/src/debugger/CartDebug.cxx index 04f58f09e..5b49deedd 100644 --- a/src/debugger/CartDebug.cxx +++ b/src/debugger/CartDebug.cxx @@ -70,11 +70,11 @@ CartDebug::CartDebug(Debugger& dbg, Console& console, const OSystem& osystem) // Banksizes greater than 4096 indicate multi-bank ROMs, but we handle only // 4K pieces at a time // Banksizes less than 4K use the actual value - int banksize = 0; + uInt32 banksize = 0; myConsole.cartridge().getImage(banksize); BankInfo info; - info.size = std::min(banksize, 4096); + info.size = std::min(banksize, 4096u); for(int i = 0; i < myConsole.cartridge().bankCount(); ++i) myBankInfo.push_back(info); diff --git a/src/emucore/Cart.cxx b/src/emucore/Cart.cxx index 05063f38c..efab74363 100644 --- a/src/emucore/Cart.cxx +++ b/src/emucore/Cart.cxx @@ -45,10 +45,10 @@ void Cartridge::setAbout(const string& about, const string& type, // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - bool Cartridge::saveROM(ofstream& out) const { - int size = -1; + uInt32 size = 0; const uInt8* image = getImage(size); - if(image == nullptr || size <= 0) + if(image == nullptr || size == 0) { cerr << "save not supported" << endl; return false; diff --git a/src/emucore/Cart.hxx b/src/emucore/Cart.hxx index ba3a0c8fd..cd6e175d3 100644 --- a/src/emucore/Cart.hxx +++ b/src/emucore/Cart.hxx @@ -146,7 +146,7 @@ class Cartridge : public Device @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - virtual const uInt8* getImage(int& size) const = 0; + virtual const uInt8* getImage(uInt32& size) const = 0; /** Informs the cartridge about the name of the ROM file used when diff --git a/src/emucore/Cart0840.cxx b/src/emucore/Cart0840.cxx index 2badd428d..6dbf41df3 100644 --- a/src/emucore/Cart0840.cxx +++ b/src/emucore/Cart0840.cxx @@ -166,7 +166,7 @@ bool Cartridge0840::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* Cartridge0840::getImage(int& size) const +const uInt8* Cartridge0840::getImage(uInt32& size) const { size = 8192; return myImage; diff --git a/src/emucore/Cart0840.hxx b/src/emucore/Cart0840.hxx index e33a07aa4..e5c5d0cbb 100644 --- a/src/emucore/Cart0840.hxx +++ b/src/emucore/Cart0840.hxx @@ -93,7 +93,7 @@ class Cartridge0840 : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/Cart2K.cxx b/src/emucore/Cart2K.cxx index 7f63582b9..c564f6bcf 100644 --- a/src/emucore/Cart2K.cxx +++ b/src/emucore/Cart2K.cxx @@ -78,7 +78,7 @@ bool Cartridge2K::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* Cartridge2K::getImage(int& size) const +const uInt8* Cartridge2K::getImage(uInt32& size) const { size = mySize; return myImage.get(); diff --git a/src/emucore/Cart2K.hxx b/src/emucore/Cart2K.hxx index 928a9e677..61d1246fe 100644 --- a/src/emucore/Cart2K.hxx +++ b/src/emucore/Cart2K.hxx @@ -79,7 +79,7 @@ class Cartridge2K : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/Cart3E.cxx b/src/emucore/Cart3E.cxx index e3261a851..a86cf1953 100644 --- a/src/emucore/Cart3E.cxx +++ b/src/emucore/Cart3E.cxx @@ -236,7 +236,7 @@ bool Cartridge3E::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* Cartridge3E::getImage(int& size) const +const uInt8* Cartridge3E::getImage(uInt32& size) const { size = mySize; return myImage.get(); diff --git a/src/emucore/Cart3E.hxx b/src/emucore/Cart3E.hxx index d0a049c1e..d5ae9e8f1 100644 --- a/src/emucore/Cart3E.hxx +++ b/src/emucore/Cart3E.hxx @@ -122,7 +122,7 @@ class Cartridge3E : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/Cart3EPlus.cxx b/src/emucore/Cart3EPlus.cxx index 174a97591..fc0d00a5b 100644 --- a/src/emucore/Cart3EPlus.cxx +++ b/src/emucore/Cart3EPlus.cxx @@ -297,7 +297,7 @@ bool Cartridge3EPlus::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* Cartridge3EPlus::getImage(int& size) const +const uInt8* Cartridge3EPlus::getImage(uInt32& size) const { size = mySize; return myImage.get(); diff --git a/src/emucore/Cart3EPlus.hxx b/src/emucore/Cart3EPlus.hxx index 81e80807c..9116f8620 100644 --- a/src/emucore/Cart3EPlus.hxx +++ b/src/emucore/Cart3EPlus.hxx @@ -83,7 +83,7 @@ class Cartridge3EPlus: public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/Cart3F.cxx b/src/emucore/Cart3F.cxx index c6c5476e7..5796b3ab4 100644 --- a/src/emucore/Cart3F.cxx +++ b/src/emucore/Cart3F.cxx @@ -164,7 +164,7 @@ bool Cartridge3F::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* Cartridge3F::getImage(int& size) const +const uInt8* Cartridge3F::getImage(uInt32& size) const { size = mySize; return myImage.get(); diff --git a/src/emucore/Cart3F.hxx b/src/emucore/Cart3F.hxx index d216fa7ca..a6f114d8b 100644 --- a/src/emucore/Cart3F.hxx +++ b/src/emucore/Cart3F.hxx @@ -99,7 +99,7 @@ class Cartridge3F : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/Cart4A50.cxx b/src/emucore/Cart4A50.cxx index 2612860ee..477c1d561 100644 --- a/src/emucore/Cart4A50.cxx +++ b/src/emucore/Cart4A50.cxx @@ -356,7 +356,7 @@ bool Cartridge4A50::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* Cartridge4A50::getImage(int& size) const +const uInt8* Cartridge4A50::getImage(uInt32& size) const { size = mySize; return myImage; diff --git a/src/emucore/Cart4A50.hxx b/src/emucore/Cart4A50.hxx index 78657bd88..60916e6a5 100644 --- a/src/emucore/Cart4A50.hxx +++ b/src/emucore/Cart4A50.hxx @@ -96,7 +96,7 @@ class Cartridge4A50 : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/Cart4K.cxx b/src/emucore/Cart4K.cxx index 295ecd00c..0f5fb4114 100644 --- a/src/emucore/Cart4K.cxx +++ b/src/emucore/Cart4K.cxx @@ -60,7 +60,7 @@ bool Cartridge4K::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* Cartridge4K::getImage(int& size) const +const uInt8* Cartridge4K::getImage(uInt32& size) const { size = 4096; return myImage; diff --git a/src/emucore/Cart4K.hxx b/src/emucore/Cart4K.hxx index f2b33624c..bc9df42c8 100644 --- a/src/emucore/Cart4K.hxx +++ b/src/emucore/Cart4K.hxx @@ -76,7 +76,7 @@ class Cartridge4K : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/Cart4KSC.cxx b/src/emucore/Cart4KSC.cxx index 20f20e6d4..253d30f6b 100644 --- a/src/emucore/Cart4KSC.cxx +++ b/src/emucore/Cart4KSC.cxx @@ -107,7 +107,7 @@ bool Cartridge4KSC::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* Cartridge4KSC::getImage(int& size) const +const uInt8* Cartridge4KSC::getImage(uInt32& size) const { size = 4096; return myImage; diff --git a/src/emucore/Cart4KSC.hxx b/src/emucore/Cart4KSC.hxx index 759c2e339..1ad6ab560 100644 --- a/src/emucore/Cart4KSC.hxx +++ b/src/emucore/Cart4KSC.hxx @@ -75,7 +75,7 @@ class Cartridge4KSC : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/CartAR.cxx b/src/emucore/CartAR.cxx index 4f4796bfb..ca0a0346c 100644 --- a/src/emucore/CartAR.cxx +++ b/src/emucore/CartAR.cxx @@ -439,7 +439,7 @@ bool CartridgeAR::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* CartridgeAR::getImage(int& size) const +const uInt8* CartridgeAR::getImage(uInt32& size) const { size = mySize; return myLoadImages.get(); diff --git a/src/emucore/CartAR.hxx b/src/emucore/CartAR.hxx index 571d61d1c..c7f13d57d 100644 --- a/src/emucore/CartAR.hxx +++ b/src/emucore/CartAR.hxx @@ -107,7 +107,7 @@ class CartridgeAR : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/CartBF.cxx b/src/emucore/CartBF.cxx index 5febd6cde..cb7187d45 100644 --- a/src/emucore/CartBF.cxx +++ b/src/emucore/CartBF.cxx @@ -125,7 +125,7 @@ bool CartridgeBF::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* CartridgeBF::getImage(int& size) const +const uInt8* CartridgeBF::getImage(uInt32& size) const { size = 64 * 4096; return myImage; diff --git a/src/emucore/CartBF.hxx b/src/emucore/CartBF.hxx index ef0c4868f..98a145b53 100644 --- a/src/emucore/CartBF.hxx +++ b/src/emucore/CartBF.hxx @@ -94,7 +94,7 @@ class CartridgeBF : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/CartBFSC.cxx b/src/emucore/CartBFSC.cxx index 07c39f423..b0628095f 100644 --- a/src/emucore/CartBFSC.cxx +++ b/src/emucore/CartBFSC.cxx @@ -173,7 +173,7 @@ bool CartridgeBFSC::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* CartridgeBFSC::getImage(int& size) const +const uInt8* CartridgeBFSC::getImage(uInt32& size) const { size = 64 * 4096; return myImage; diff --git a/src/emucore/CartBFSC.hxx b/src/emucore/CartBFSC.hxx index b88bd3990..e5becb811 100644 --- a/src/emucore/CartBFSC.hxx +++ b/src/emucore/CartBFSC.hxx @@ -94,7 +94,7 @@ class CartridgeBFSC : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/CartBUS.cxx b/src/emucore/CartBUS.cxx index 1074170ec..cb733b47b 100644 --- a/src/emucore/CartBUS.cxx +++ b/src/emucore/CartBUS.cxx @@ -488,7 +488,7 @@ bool CartridgeBUS::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* CartridgeBUS::getImage(int& size) const +const uInt8* CartridgeBUS::getImage(uInt32& size) const { size = 32768; return myImage; diff --git a/src/emucore/CartBUS.hxx b/src/emucore/CartBUS.hxx index d4ed325b7..58f335e7a 100644 --- a/src/emucore/CartBUS.hxx +++ b/src/emucore/CartBUS.hxx @@ -120,7 +120,7 @@ class CartridgeBUS : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/CartCDF.cxx b/src/emucore/CartCDF.cxx index b781332c5..7c1f1c2c7 100644 --- a/src/emucore/CartCDF.cxx +++ b/src/emucore/CartCDF.cxx @@ -452,7 +452,7 @@ bool CartridgeCDF::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* CartridgeCDF::getImage(int& size) const +const uInt8* CartridgeCDF::getImage(uInt32& size) const { size = 32768; return myImage; diff --git a/src/emucore/CartCDF.hxx b/src/emucore/CartCDF.hxx index 4ef48fc8c..02f4298ac 100644 --- a/src/emucore/CartCDF.hxx +++ b/src/emucore/CartCDF.hxx @@ -120,7 +120,7 @@ class CartridgeCDF : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/CartCM.cxx b/src/emucore/CartCM.cxx index 0ea863614..a5309377d 100644 --- a/src/emucore/CartCM.cxx +++ b/src/emucore/CartCM.cxx @@ -181,7 +181,7 @@ bool CartridgeCM::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* CartridgeCM::getImage(int& size) const +const uInt8* CartridgeCM::getImage(uInt32& size) const { size = 16384; return myImage; diff --git a/src/emucore/CartCM.hxx b/src/emucore/CartCM.hxx index 61cf4b156..94aef6c3a 100644 --- a/src/emucore/CartCM.hxx +++ b/src/emucore/CartCM.hxx @@ -168,7 +168,7 @@ class CartridgeCM : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/CartCTY.cxx b/src/emucore/CartCTY.cxx index 19226b06a..f1110dd37 100644 --- a/src/emucore/CartCTY.cxx +++ b/src/emucore/CartCTY.cxx @@ -277,7 +277,7 @@ bool CartridgeCTY::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* CartridgeCTY::getImage(int& size) const +const uInt8* CartridgeCTY::getImage(uInt32& size) const { size = 32768; return myImage; diff --git a/src/emucore/CartCTY.hxx b/src/emucore/CartCTY.hxx index 6cb940e0f..81e524744 100644 --- a/src/emucore/CartCTY.hxx +++ b/src/emucore/CartCTY.hxx @@ -177,7 +177,7 @@ class CartridgeCTY : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/CartCV.cxx b/src/emucore/CartCV.cxx index 202b65214..b75fdf341 100644 --- a/src/emucore/CartCV.cxx +++ b/src/emucore/CartCV.cxx @@ -132,7 +132,7 @@ bool CartridgeCV::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* CartridgeCV::getImage(int& size) const +const uInt8* CartridgeCV::getImage(uInt32& size) const { size = 2048; return myImage; diff --git a/src/emucore/CartCV.hxx b/src/emucore/CartCV.hxx index 0a6e3411b..f523ede46 100644 --- a/src/emucore/CartCV.hxx +++ b/src/emucore/CartCV.hxx @@ -79,7 +79,7 @@ class CartridgeCV : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/CartCVPlus.cxx b/src/emucore/CartCVPlus.cxx index c9bf1d258..e4f6c02f4 100644 --- a/src/emucore/CartCVPlus.cxx +++ b/src/emucore/CartCVPlus.cxx @@ -189,7 +189,7 @@ bool CartridgeCVPlus::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* CartridgeCVPlus::getImage(int& size) const +const uInt8* CartridgeCVPlus::getImage(uInt32& size) const { size = mySize; return myImage.get(); diff --git a/src/emucore/CartCVPlus.hxx b/src/emucore/CartCVPlus.hxx index f60bfa7a2..bd513a862 100644 --- a/src/emucore/CartCVPlus.hxx +++ b/src/emucore/CartCVPlus.hxx @@ -106,7 +106,7 @@ class CartridgeCVPlus : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/CartDASH.cxx b/src/emucore/CartDASH.cxx index 814c1fbed..c6b038fa2 100644 --- a/src/emucore/CartDASH.cxx +++ b/src/emucore/CartDASH.cxx @@ -302,7 +302,7 @@ bool CartridgeDASH::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* CartridgeDASH::getImage(int& size) const +const uInt8* CartridgeDASH::getImage(uInt32& size) const { size = mySize; return myImage.get(); diff --git a/src/emucore/CartDASH.hxx b/src/emucore/CartDASH.hxx index 446e162cf..372258ea0 100644 --- a/src/emucore/CartDASH.hxx +++ b/src/emucore/CartDASH.hxx @@ -165,7 +165,7 @@ class CartridgeDASH: public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/CartDF.cxx b/src/emucore/CartDF.cxx index 383e4c27e..b70bb500a 100644 --- a/src/emucore/CartDF.cxx +++ b/src/emucore/CartDF.cxx @@ -121,7 +121,7 @@ bool CartridgeDF::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* CartridgeDF::getImage(int& size) const +const uInt8* CartridgeDF::getImage(uInt32& size) const { size = 131072; return myImage; diff --git a/src/emucore/CartDF.hxx b/src/emucore/CartDF.hxx index 1b6cb7b42..74a05958b 100644 --- a/src/emucore/CartDF.hxx +++ b/src/emucore/CartDF.hxx @@ -94,7 +94,7 @@ class CartridgeDF : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/CartDFSC.cxx b/src/emucore/CartDFSC.cxx index c182d6b2d..7410a471b 100644 --- a/src/emucore/CartDFSC.cxx +++ b/src/emucore/CartDFSC.cxx @@ -173,7 +173,7 @@ bool CartridgeDFSC::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* CartridgeDFSC::getImage(int& size) const +const uInt8* CartridgeDFSC::getImage(uInt32& size) const { size = 131072; return myImage; diff --git a/src/emucore/CartDFSC.hxx b/src/emucore/CartDFSC.hxx index 4de778db3..dc41285aa 100644 --- a/src/emucore/CartDFSC.hxx +++ b/src/emucore/CartDFSC.hxx @@ -94,7 +94,7 @@ class CartridgeDFSC : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/CartDPC.cxx b/src/emucore/CartDPC.cxx index dbebab85b..948ac7260 100644 --- a/src/emucore/CartDPC.cxx +++ b/src/emucore/CartDPC.cxx @@ -446,7 +446,7 @@ bool CartridgeDPC::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* CartridgeDPC::getImage(int& size) const +const uInt8* CartridgeDPC::getImage(uInt32& size) const { size = mySize; return myImage; diff --git a/src/emucore/CartDPC.hxx b/src/emucore/CartDPC.hxx index de0f04e9c..c1b53ba23 100644 --- a/src/emucore/CartDPC.hxx +++ b/src/emucore/CartDPC.hxx @@ -105,7 +105,7 @@ class CartridgeDPC : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/CartDPCPlus.cxx b/src/emucore/CartDPCPlus.cxx index 6e1a46320..864ede1d6 100644 --- a/src/emucore/CartDPCPlus.cxx +++ b/src/emucore/CartDPCPlus.cxx @@ -636,7 +636,7 @@ bool CartridgeDPCPlus::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* CartridgeDPCPlus::getImage(int& size) const +const uInt8* CartridgeDPCPlus::getImage(uInt32& size) const { size = mySize; return myImage + (32768u - mySize); diff --git a/src/emucore/CartDPCPlus.hxx b/src/emucore/CartDPCPlus.hxx index 6dc9ee0b9..15e064a3f 100644 --- a/src/emucore/CartDPCPlus.hxx +++ b/src/emucore/CartDPCPlus.hxx @@ -121,7 +121,7 @@ class CartridgeDPCPlus : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/CartE0.cxx b/src/emucore/CartE0.cxx index 270f9ee4a..f11dc9f5d 100644 --- a/src/emucore/CartE0.cxx +++ b/src/emucore/CartE0.cxx @@ -187,7 +187,7 @@ bool CartridgeE0::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* CartridgeE0::getImage(int& size) const +const uInt8* CartridgeE0::getImage(uInt32& size) const { size = 8192; return myImage; diff --git a/src/emucore/CartE0.hxx b/src/emucore/CartE0.hxx index 0ceaaa67c..12063254c 100644 --- a/src/emucore/CartE0.hxx +++ b/src/emucore/CartE0.hxx @@ -85,7 +85,7 @@ class CartridgeE0 : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/CartE7.cxx b/src/emucore/CartE7.cxx index 39ca2a63e..d98387d85 100644 --- a/src/emucore/CartE7.cxx +++ b/src/emucore/CartE7.cxx @@ -264,7 +264,7 @@ bool CartridgeE7::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* CartridgeE7::getImage(int& size) const +const uInt8* CartridgeE7::getImage(uInt32& size) const { size = 16384; return myImage; diff --git a/src/emucore/CartE7.hxx b/src/emucore/CartE7.hxx index c27332f1f..86ec30a42 100644 --- a/src/emucore/CartE7.hxx +++ b/src/emucore/CartE7.hxx @@ -119,7 +119,7 @@ class CartridgeE7 : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/CartEF.cxx b/src/emucore/CartEF.cxx index e61627d5e..5f58e5495 100644 --- a/src/emucore/CartEF.cxx +++ b/src/emucore/CartEF.cxx @@ -121,7 +121,7 @@ bool CartridgeEF::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* CartridgeEF::getImage(int& size) const +const uInt8* CartridgeEF::getImage(uInt32& size) const { size = 65536; return myImage; diff --git a/src/emucore/CartEF.hxx b/src/emucore/CartEF.hxx index 151f7919c..624b1b938 100644 --- a/src/emucore/CartEF.hxx +++ b/src/emucore/CartEF.hxx @@ -94,7 +94,7 @@ class CartridgeEF : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/CartEFSC.cxx b/src/emucore/CartEFSC.cxx index ccaa7cf7b..e9e033877 100644 --- a/src/emucore/CartEFSC.cxx +++ b/src/emucore/CartEFSC.cxx @@ -173,7 +173,7 @@ bool CartridgeEFSC::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* CartridgeEFSC::getImage(int& size) const +const uInt8* CartridgeEFSC::getImage(uInt32& size) const { size = 65536; return myImage; diff --git a/src/emucore/CartEFSC.hxx b/src/emucore/CartEFSC.hxx index 6b6f53629..30e328b9e 100644 --- a/src/emucore/CartEFSC.hxx +++ b/src/emucore/CartEFSC.hxx @@ -95,7 +95,7 @@ class CartridgeEFSC : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/CartF0.cxx b/src/emucore/CartF0.cxx index e1d85fc53..4c4365d89 100644 --- a/src/emucore/CartF0.cxx +++ b/src/emucore/CartF0.cxx @@ -130,7 +130,7 @@ bool CartridgeF0::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* CartridgeF0::getImage(int& size) const +const uInt8* CartridgeF0::getImage(uInt32& size) const { size = 65536; return myImage; diff --git a/src/emucore/CartF0.hxx b/src/emucore/CartF0.hxx index 7e6ea864c..aa81d68f3 100644 --- a/src/emucore/CartF0.hxx +++ b/src/emucore/CartF0.hxx @@ -94,7 +94,7 @@ class CartridgeF0 : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/CartF4.cxx b/src/emucore/CartF4.cxx index 2063dbaae..592c15b85 100644 --- a/src/emucore/CartF4.cxx +++ b/src/emucore/CartF4.cxx @@ -126,7 +126,7 @@ bool CartridgeF4::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* CartridgeF4::getImage(int& size) const +const uInt8* CartridgeF4::getImage(uInt32& size) const { size = 32768; return myImage; diff --git a/src/emucore/CartF4.hxx b/src/emucore/CartF4.hxx index a27326a49..8372a0206 100644 --- a/src/emucore/CartF4.hxx +++ b/src/emucore/CartF4.hxx @@ -93,7 +93,7 @@ class CartridgeF4 : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/CartF4SC.cxx b/src/emucore/CartF4SC.cxx index 4e4a3f698..4d8e3a908 100644 --- a/src/emucore/CartF4SC.cxx +++ b/src/emucore/CartF4SC.cxx @@ -176,7 +176,7 @@ bool CartridgeF4SC::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* CartridgeF4SC::getImage(int& size) const +const uInt8* CartridgeF4SC::getImage(uInt32& size) const { size = 32768; return myImage; diff --git a/src/emucore/CartF4SC.hxx b/src/emucore/CartF4SC.hxx index 1d97f560b..d26ecb49c 100644 --- a/src/emucore/CartF4SC.hxx +++ b/src/emucore/CartF4SC.hxx @@ -94,7 +94,7 @@ class CartridgeF4SC : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/CartF6.cxx b/src/emucore/CartF6.cxx index cc1460943..ec95262d1 100644 --- a/src/emucore/CartF6.cxx +++ b/src/emucore/CartF6.cxx @@ -166,7 +166,7 @@ bool CartridgeF6::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* CartridgeF6::getImage(int& size) const +const uInt8* CartridgeF6::getImage(uInt32& size) const { size = 16384; return myImage; diff --git a/src/emucore/CartF6.hxx b/src/emucore/CartF6.hxx index d9b95971d..15d9d1085 100644 --- a/src/emucore/CartF6.hxx +++ b/src/emucore/CartF6.hxx @@ -93,7 +93,7 @@ class CartridgeF6 : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/CartF6SC.cxx b/src/emucore/CartF6SC.cxx index cc4dd385d..d50810750 100644 --- a/src/emucore/CartF6SC.cxx +++ b/src/emucore/CartF6SC.cxx @@ -219,7 +219,7 @@ bool CartridgeF6SC::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* CartridgeF6SC::getImage(int& size) const +const uInt8* CartridgeF6SC::getImage(uInt32& size) const { size = 16384; return myImage; diff --git a/src/emucore/CartF6SC.hxx b/src/emucore/CartF6SC.hxx index 310fca9b1..401d0ac79 100644 --- a/src/emucore/CartF6SC.hxx +++ b/src/emucore/CartF6SC.hxx @@ -94,7 +94,7 @@ class CartridgeF6SC : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/CartF8.cxx b/src/emucore/CartF8.cxx index 7ef3faf51..e60269f53 100644 --- a/src/emucore/CartF8.cxx +++ b/src/emucore/CartF8.cxx @@ -154,7 +154,7 @@ bool CartridgeF8::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* CartridgeF8::getImage(int& size) const +const uInt8* CartridgeF8::getImage(uInt32& size) const { size = 8192; return myImage; diff --git a/src/emucore/CartF8.hxx b/src/emucore/CartF8.hxx index 4184a3e91..8504f67b1 100644 --- a/src/emucore/CartF8.hxx +++ b/src/emucore/CartF8.hxx @@ -95,7 +95,7 @@ class CartridgeF8 : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/CartF8SC.cxx b/src/emucore/CartF8SC.cxx index 265888553..85cc22ec1 100644 --- a/src/emucore/CartF8SC.cxx +++ b/src/emucore/CartF8SC.cxx @@ -199,7 +199,7 @@ bool CartridgeF8SC::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* CartridgeF8SC::getImage(int& size) const +const uInt8* CartridgeF8SC::getImage(uInt32& size) const { size = 8192; return myImage; diff --git a/src/emucore/CartF8SC.hxx b/src/emucore/CartF8SC.hxx index 06a22eeaf..f19f22a79 100644 --- a/src/emucore/CartF8SC.hxx +++ b/src/emucore/CartF8SC.hxx @@ -94,7 +94,7 @@ class CartridgeF8SC : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/CartFA.cxx b/src/emucore/CartFA.cxx index 2cfc615c1..9e77735d0 100644 --- a/src/emucore/CartFA.cxx +++ b/src/emucore/CartFA.cxx @@ -209,7 +209,7 @@ bool CartridgeFA::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* CartridgeFA::getImage(int& size) const +const uInt8* CartridgeFA::getImage(uInt32& size) const { size = 12288; return myImage; diff --git a/src/emucore/CartFA.hxx b/src/emucore/CartFA.hxx index d7e916d65..0018afd0d 100644 --- a/src/emucore/CartFA.hxx +++ b/src/emucore/CartFA.hxx @@ -94,7 +94,7 @@ class CartridgeFA : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/CartFA2.cxx b/src/emucore/CartFA2.cxx index bf2c094e5..bcc61df54 100644 --- a/src/emucore/CartFA2.cxx +++ b/src/emucore/CartFA2.cxx @@ -275,7 +275,7 @@ bool CartridgeFA2::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* CartridgeFA2::getImage(int& size) const +const uInt8* CartridgeFA2::getImage(uInt32& size) const { size = mySize; return myImage; diff --git a/src/emucore/CartFA2.hxx b/src/emucore/CartFA2.hxx index 39ee08347..caf8c0f4c 100644 --- a/src/emucore/CartFA2.hxx +++ b/src/emucore/CartFA2.hxx @@ -106,7 +106,7 @@ class CartridgeFA2 : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/CartFE.cxx b/src/emucore/CartFE.cxx index 45b15692a..b569be0f3 100644 --- a/src/emucore/CartFE.cxx +++ b/src/emucore/CartFE.cxx @@ -127,7 +127,7 @@ bool CartridgeFE::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* CartridgeFE::getImage(int& size) const +const uInt8* CartridgeFE::getImage(uInt32& size) const { size = 8192; return myImage; diff --git a/src/emucore/CartFE.hxx b/src/emucore/CartFE.hxx index a02419d35..d26988dc5 100644 --- a/src/emucore/CartFE.hxx +++ b/src/emucore/CartFE.hxx @@ -136,7 +136,7 @@ class CartridgeFE : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/CartMDM.cxx b/src/emucore/CartMDM.cxx index 7a2ebee72..4dabd885b 100644 --- a/src/emucore/CartMDM.cxx +++ b/src/emucore/CartMDM.cxx @@ -145,7 +145,7 @@ bool CartridgeMDM::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* CartridgeMDM::getImage(int& size) const +const uInt8* CartridgeMDM::getImage(uInt32& size) const { size = mySize; return myImage.get(); diff --git a/src/emucore/CartMDM.hxx b/src/emucore/CartMDM.hxx index 769bccf1c..1be154e60 100644 --- a/src/emucore/CartMDM.hxx +++ b/src/emucore/CartMDM.hxx @@ -105,7 +105,7 @@ class CartridgeMDM : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/CartSB.cxx b/src/emucore/CartSB.cxx index 4b11e0cb5..42afc6f22 100644 --- a/src/emucore/CartSB.cxx +++ b/src/emucore/CartSB.cxx @@ -150,7 +150,7 @@ bool CartridgeSB::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* CartridgeSB::getImage(int& size) const +const uInt8* CartridgeSB::getImage(uInt32& size) const { size = mySize; return myImage.get(); diff --git a/src/emucore/CartSB.hxx b/src/emucore/CartSB.hxx index 53421aaf2..eb8324702 100644 --- a/src/emucore/CartSB.hxx +++ b/src/emucore/CartSB.hxx @@ -94,7 +94,7 @@ class CartridgeSB : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/CartUA.cxx b/src/emucore/CartUA.cxx index aaf22e230..40119f2b0 100644 --- a/src/emucore/CartUA.cxx +++ b/src/emucore/CartUA.cxx @@ -156,7 +156,7 @@ bool CartridgeUA::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* CartridgeUA::getImage(int& size) const +const uInt8* CartridgeUA::getImage(uInt32& size) const { size = 8192; return myImage; diff --git a/src/emucore/CartUA.hxx b/src/emucore/CartUA.hxx index 2a52d9f96..0ff1bfd26 100644 --- a/src/emucore/CartUA.hxx +++ b/src/emucore/CartUA.hxx @@ -94,7 +94,7 @@ class CartridgeUA : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/CartWD.cxx b/src/emucore/CartWD.cxx index 08454a5a5..89a395a9e 100644 --- a/src/emucore/CartWD.cxx +++ b/src/emucore/CartWD.cxx @@ -261,7 +261,7 @@ bool CartridgeWD::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* CartridgeWD::getImage(int& size) const +const uInt8* CartridgeWD::getImage(uInt32& size) const { size = mySize; return myImage; diff --git a/src/emucore/CartWD.hxx b/src/emucore/CartWD.hxx index aff9a3ee2..b9596537b 100644 --- a/src/emucore/CartWD.hxx +++ b/src/emucore/CartWD.hxx @@ -122,7 +122,7 @@ class CartridgeWD : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer. diff --git a/src/emucore/CartX07.cxx b/src/emucore/CartX07.cxx index 6ffe4138a..fa526a4dd 100644 --- a/src/emucore/CartX07.cxx +++ b/src/emucore/CartX07.cxx @@ -145,7 +145,7 @@ bool CartridgeX07::patch(uInt16 address, uInt8 value) } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -const uInt8* CartridgeX07::getImage(int& size) const +const uInt8* CartridgeX07::getImage(uInt32& size) const { size = 65536; return myImage; diff --git a/src/emucore/CartX07.hxx b/src/emucore/CartX07.hxx index c3f2d8e7b..7d6d63cbc 100644 --- a/src/emucore/CartX07.hxx +++ b/src/emucore/CartX07.hxx @@ -103,7 +103,7 @@ class CartridgeX07 : public Cartridge @param size Set to the size of the internal ROM image data @return A pointer to the internal ROM image data */ - const uInt8* getImage(int& size) const override; + const uInt8* getImage(uInt32& size) const override; /** Save the current state of this cart to the given Serializer.