Asserts: break/crash program, fit to style guide; log.h->assert.h
Involves making asserts use printf instead of the log functions (log functions are asynchronous and, as such, the log won't be printed in time) As such, the log type argument was removed (printf obviously can't use it, and it's made obsolete by the file and line printing) Also removed some GEKKO cruft.
This commit is contained in:
parent
168eb27aee
commit
ef24e72b26
88 changed files with 135 additions and 217 deletions
|
@ -3,7 +3,6 @@
|
|||
// Refer to the license.txt file included.
|
||||
|
||||
#include <algorithm>
|
||||
#include "common/log.h"
|
||||
#include "common/make_unique.h"
|
||||
#include "core/file_sys/archive_systemsavedata.h"
|
||||
#include "core/hle/service/cfg/cfg.h"
|
||||
|
@ -109,7 +108,7 @@ ResultCode UpdateConfigNANDSavegame() {
|
|||
mode.create_flag = 1;
|
||||
FileSys::Path path("config");
|
||||
auto file = cfg_system_save_data->OpenFile(path, mode);
|
||||
_assert_msg_(Service_CFG, file != nullptr, "could not open file");
|
||||
ASSERT_MSG(file != nullptr, "could not open file");
|
||||
file->Write(0, CONFIG_SAVEFILE_SIZE, 1, cfg_config_file_buffer.data());
|
||||
return RESULT_SUCCESS;
|
||||
}
|
||||
|
|
|
@ -2,7 +2,6 @@
|
|||
// Licensed under GPLv2 or any later version
|
||||
// Refer to the license.txt file included.
|
||||
|
||||
#include "common/log.h"
|
||||
#include "core/hle/hle.h"
|
||||
#include "core/hle/service/cfg/cfg.h"
|
||||
#include "core/hle/service/cfg/cfg_i.h"
|
||||
|
|
|
@ -2,7 +2,6 @@
|
|||
// Licensed under GPLv2 or any later version
|
||||
// Refer to the license.txt file included.
|
||||
|
||||
#include "common/log.h"
|
||||
#include "core/hle/hle.h"
|
||||
#include "core/hle/service/cfg/cfg.h"
|
||||
#include "core/hle/service/cfg/cfg_s.h"
|
||||
|
|
|
@ -3,7 +3,6 @@
|
|||
// Refer to the license.txt file included.
|
||||
|
||||
#include "common/file_util.h"
|
||||
#include "common/log.h"
|
||||
#include "common/string_util.h"
|
||||
#include "core/settings.h"
|
||||
#include "core/file_sys/archive_systemsavedata.h"
|
||||
|
@ -84,7 +83,7 @@ static void GetCountryCodeID(Service::Interface* self) {
|
|||
u16 country_code_id = 0;
|
||||
|
||||
// The following algorithm will fail if the first country code isn't 0.
|
||||
_dbg_assert_(Service_CFG, country_codes[0] == 0);
|
||||
DEBUG_ASSERT(country_codes[0] == 0);
|
||||
|
||||
for (size_t id = 0; id < country_codes.size(); ++id) {
|
||||
if (country_codes[id] == country_code) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue