Skip to content

Commit 33a20b9

Browse files
committed
UPBGE: Replace NULL by nullptr.
1 parent c2319e3 commit 33a20b9

File tree

2 files changed

+9
-9
lines changed

2 files changed

+9
-9
lines changed

source/gameengine/Expressions/intern/BaseListValue.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ EXP_Value *EXP_BaseListValue::FindValue(const std::string& name) const
5959
if (it != m_pValueArray.end()) {
6060
return *it;
6161
}
62-
return NULL;
62+
return nullptr;
6363
}
6464

6565
bool EXP_BaseListValue::SearchValue(EXP_Value *val) const
@@ -96,7 +96,7 @@ bool EXP_BaseListValue::CheckEqual(EXP_Value *first, EXP_Value *second)
9696
{
9797
bool result = false;
9898
EXP_Value *eqval = first->Calc(VALUE_EQL_OPERATOR, second);
99-
if (eqval == NULL) {
99+
if (eqval == nullptr) {
100100
return false;
101101
}
102102
std::string text = eqval->GetText();

source/gameengine/GamePlayer/GPG_ghost.cpp

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -249,7 +249,7 @@ static HWND findGhostWindowHWND(GHOST_IWindow* window)
249249
{
250250
found_ghost_window_hwnd = nullptr;
251251
ghost_window_to_find = window;
252-
EnumWindows(findGhostWindowHWNDProc, NULL);
252+
EnumWindows(findGhostWindowHWNDProc, nullptr);
253253
return found_ghost_window_hwnd;
254254
}
255255

@@ -595,14 +595,14 @@ static bool quitGame(KX_ExitRequest exitcode)
595595
static BlendFileData *load_encrypted_game_data(const char *filename, std::string encryptKey)
596596
{
597597
ReportList reports;
598-
BlendFileData *bfd = NULL;
599-
char *fileData = NULL;
598+
BlendFileData *bfd = nullptr;
599+
char *fileData = nullptr;
600600
int fileSize;
601601
std::string localPath(SPINDLE_GetFilePath());
602602
BKE_reports_init(&reports, RPT_STORE);
603603

604-
if (filename == NULL) {
605-
return NULL;
604+
if (filename == nullptr) {
605+
return nullptr;
606606
}
607607

608608
if (!localPath.empty() && !encryptKey.empty()) {
@@ -1171,7 +1171,7 @@ int main(
11711171
{
11721172
#ifdef WITH_GAMEENGINE_BPPLAYER
11731173
if (useLocalPath) {
1174-
bfd = load_encrypted_game_data(filename[0] ? filename : NULL, hexKey);
1174+
bfd = load_encrypted_game_data(filename[0] ? filename : nullptr, hexKey);
11751175

11761176
// The file is valid and it's the original file name.
11771177
if (bfd) {
@@ -1182,7 +1182,7 @@ int main(
11821182
else
11831183
#endif // WITH_GAMEENGINE_BPPLAYER
11841184
{
1185-
bfd = load_game_data(BKE_appdir_program_path(), filename[0] ? filename : NULL);
1185+
bfd = load_game_data(BKE_appdir_program_path(), filename[0] ? filename : nullptr);
11861186
// The file is valid and it's the original file name.
11871187
if (bfd)
11881188
KX_SetOrigPath(bfd->main->name);

0 commit comments

Comments
 (0)