CGE2: Use nullptr

Using clang-tidy modernize-use-nullptr
This commit is contained in:
Orgad Shaneh 2021-11-13 23:40:18 +02:00 committed by Filippos Karapetis
parent 69f45d9258
commit 7f476c844f
3 changed files with 6 additions and 6 deletions

View File

@ -43,7 +43,7 @@ namespace CGE2 {
static const PlainGameDescriptor CGE2Games[] = {
{ "sfinx", "Sfinx" },
{ 0, 0 }
{ nullptr, nullptr }
};
static const ADGameDescription gameDescriptions[] = {
@ -162,7 +162,7 @@ public:
static ADGameDescription s_fallbackDesc = {
"sfinx",
"Unknown version",
AD_ENTRY1(0, 0), // This should always be AD_ENTRY1(0, 0) in the fallback descriptor
AD_ENTRY1(nullptr, nullptr), // This should always be AD_ENTRY1(0, 0) in the fallback descriptor
Common::UNK_LANG,
Common::kPlatformDOS,
ADGF_NO_FLAGS,
@ -170,8 +170,8 @@ static ADGameDescription s_fallbackDesc = {
};
static const ADFileBasedFallback fileBasedFallback[] = {
{ &s_fallbackDesc, { "vol.cat", "vol.dat", 0 } },
{ 0, { 0 } }
{ &s_fallbackDesc, { "vol.cat", "vol.dat", nullptr } },
{ nullptr, { nullptr } }
};
// This fallback detection looks identical to the one used for CGE. In fact, the difference resides

View File

@ -56,7 +56,7 @@ bool Keyboard::getKey(Common::Event &event) {
return false;
// Display ScummVM version and translation strings
for (int i = 0; i < 3; i++)
_vm->_commandHandler->addCommand(kCmdInf, 1, kShowScummVMVersion + i, NULL);
_vm->_commandHandler->addCommand(kCmdInf, 1, kShowScummVMVersion + i, nullptr);
return false;
case Common::KEYCODE_F5:
_vm->saveGameDialog();

View File

@ -170,7 +170,7 @@ DataCk *Fx::loadWave(EncryptedStream *file) {
byte *data = (byte *)malloc(file->size());
if (!data)
return 0;
return nullptr;
file->read(data, file->size());