[Scummvm-git-logs] scummvm master -> 7f5f248ecb9ec6b19953ae8b95e93114c6522941
Strangerke
noreply at scummvm.org
Mon May 20 11:32:30 UTC 2024
This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .
Summary:
7f5f248ecb BAGEL: Fix several false positive null dereferencing before null check by remove useless nulls checks
Commit: 7f5f248ecb9ec6b19953ae8b95e93114c6522941
https://github.com/scummvm/scummvm/commit/7f5f248ecb9ec6b19953ae8b95e93114c6522941
Author: Strangerke (arnaud.boutonne at gmail.com)
Date: 2024-05-20T12:32:19+01:00
Commit Message:
BAGEL: Fix several false positive null dereferencing before null check by remove useless nulls checks
Changed paths:
engines/bagel/spacebar/spacebar.cpp
diff --git a/engines/bagel/spacebar/spacebar.cpp b/engines/bagel/spacebar/spacebar.cpp
index ad5144199cc..19d0d122fe8 100644
--- a/engines/bagel/spacebar/spacebar.cpp
+++ b/engines/bagel/spacebar/spacebar.cpp
@@ -133,16 +133,13 @@ ErrorCode SpaceBarEngine::initialize() {
bRestart = true;
// Hide that dialog
- if (pBmp != nullptr) {
- pBmp->paint(_masterWin, 0, 0);
- }
+ pBmp->paint(_masterWin, 0, 0);
break;
case QUIT_BTN:
// Hide that dialog
- if (pBmp != nullptr) {
- pBmp->paint(_masterWin, 0, 0);
- }
+ pBmp->paint(_masterWin, 0, 0);
+
_masterWin->close();
_masterWin = nullptr;
break;
@@ -161,9 +158,7 @@ ErrorCode SpaceBarEngine::initialize() {
// Play the movie only if it exists
if (fileExists(cString.getBuffer())) {
bofPlayMovie(_masterWin, cString.getBuffer());
- if (pBmp != nullptr) {
- pBmp->paint(_masterWin, 0, 0);
- }
+ pBmp->paint(_masterWin, 0, 0);
}
if (shouldQuit())
goto exit;
@@ -172,9 +167,7 @@ ErrorCode SpaceBarEngine::initialize() {
fixPathName(cString);
if (fileExists(cString.getBuffer())) {
bofPlayMovie(_masterWin, cString.getBuffer());
- if (pBmp != nullptr) {
- pBmp->paint(_masterWin, 0, 0);
- }
+ pBmp->paint(_masterWin, 0, 0);
}
if (shouldQuit())
goto exit;
@@ -185,9 +178,7 @@ ErrorCode SpaceBarEngine::initialize() {
if (fileExists(cString.getBuffer())) {
bofPlayMovie(_masterWin, cString.getBuffer());
- if (pBmp != nullptr) {
- pBmp->paint(_masterWin, 0, 0);
- }
+ pBmp->paint(_masterWin, 0, 0);
}
}
if (shouldQuit())
More information about the Scummvm-git-logs
mailing list