diff options
author | Miodrag Milanovic <mmicko@gmail.com> | 2015-12-04 07:02:00 +0100 |
---|---|---|
committer | Miodrag Milanovic <mmicko@gmail.com> | 2015-12-04 07:02:00 +0100 |
commit | 68f961927a156c47cb444c1f66258a89342d0205 (patch) | |
tree | b0d5753d5658e62ecca72d37af2f79dfc7f808bb /src/devices/bus/gba/gba_slot.cpp | |
parent | 029a3003631093ffaf1a0318e0c58b3e173403a3 (diff) |
clang-modernize part 2
Diffstat (limited to 'src/devices/bus/gba/gba_slot.cpp')
-rw-r--r-- | src/devices/bus/gba/gba_slot.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/devices/bus/gba/gba_slot.cpp b/src/devices/bus/gba/gba_slot.cpp index 2ae46b80864..2618b7ad09f 100644 --- a/src/devices/bus/gba/gba_slot.cpp +++ b/src/devices/bus/gba/gba_slot.cpp @@ -28,7 +28,7 @@ const device_type GBA_CART_SLOT = &device_creator<gba_cart_slot_device>; device_gba_cart_interface::device_gba_cart_interface(const machine_config &mconfig, device_t &device) : device_slot_card_interface(mconfig, device), - m_rom(NULL), + m_rom(nullptr), m_rom_size(0) { } @@ -48,7 +48,7 @@ device_gba_cart_interface::~device_gba_cart_interface() void device_gba_cart_interface::rom_alloc(UINT32 size, const char *tag) { - if (m_rom == NULL) + if (m_rom == nullptr) { // we always alloc 32MB of rom region! m_rom = (UINT32 *)device().machine().memory().region_alloc(std::string(tag).append(GBASLOT_ROM_REGION_TAG).c_str(), 0x2000000, 4, ENDIANNESS_LITTLE)->base(); @@ -168,7 +168,7 @@ bool gba_cart_slot_device::call_load() if (m_cart) { UINT8 *ROM; - UINT32 size = (software_entry() != NULL) ? get_software_region_length("rom") : length(); + UINT32 size = (software_entry() != nullptr) ? get_software_region_length("rom") : length(); if (size > 0x2000000) { seterror(IMAGE_ERROR_UNSPECIFIED, "Attempted loading a cart larger than 32MB"); @@ -178,7 +178,7 @@ bool gba_cart_slot_device::call_load() m_cart->rom_alloc(size, tag()); ROM = (UINT8 *)m_cart->get_rom_base(); - if (software_entry() == NULL) + if (software_entry() == nullptr) { fread(ROM, size); m_type = get_cart_type(ROM, size); |