replace __debugbreak with assert, fix full build

This commit is contained in:
Tropical
2026-04-07 18:58:49 -05:00
parent 6faa481013
commit e4883d87fc
60 changed files with 105 additions and 120 deletions

View File

@@ -15,6 +15,7 @@
#include <thread>
#include <utility>
#include "platform/fs/fs.h"
#include "platform/PlatformTypes.h"
#include "minecraft/GameEnums.h"
#include "app/common/BuildVer/BuildVer.h"
@@ -469,7 +470,7 @@ void ConsoleSaveFileSplit::_init(const std::wstring& fileName, void* pvSaveData,
// pages committed should always be zero at this point.
if (pagesCommitted != 0) {
#if !defined(_CONTENT_PACKAGE)
__debugbreak();
assert(0);
#endif
}
@@ -481,7 +482,7 @@ void ConsoleSaveFileSplit::_init(const std::wstring& fileName, void* pvSaveData,
if (pvRet == nullptr) {
#if !defined(_CONTENT_PACKAGE)
// Out of physical memory
__debugbreak();
assert(0);
#endif
}
pagesCommitted = pagesRequired;
@@ -530,7 +531,7 @@ void ConsoleSaveFileSplit::_init(const std::wstring& fileName, void* pvSaveData,
COMMIT_ALLOCATION, PAGE_READWRITE);
if (pvRet == nullptr) {
// Out of physical memory
__debugbreak();
assert(0);
}
pagesCommitted = pagesRequired;
}
@@ -541,7 +542,7 @@ void ConsoleSaveFileSplit::_init(const std::wstring& fileName, void* pvSaveData,
// actually be ok
Log::info("Failed to decompress save data!\n");
#if !defined(_CONTENT_PACKAGE)
__debugbreak();
assert(0);
#endif
memset(pvSaveMem, 0, fileSize);
// Clear the first 8 bytes that reference the header
@@ -1036,7 +1037,7 @@ void ConsoleSaveFileSplit::MoveDataBeyond(FileEntry* file,
COMMIT_ALLOCATION, PAGE_READWRITE);
if (pvRet == nullptr) {
// Out of physical memory
__debugbreak();
assert(0);
}
pagesCommitted = pagesRequired;
}