mirror of
https://github.com/Detanup01/gbe_fork.git
synced 2024-12-25 09:54:15 +08:00
fix that problem for Linux compilation
This commit is contained in:
parent
7c95d41634
commit
0c4344e1bf
@ -160,6 +160,7 @@ static inline void reset_LastError()
|
||||
#define PATH_MAX_STRING_SIZE 512
|
||||
#define PATH_SEPARATOR "/"
|
||||
#define utf8_decode(a) a
|
||||
#define utf8_encode(a) a
|
||||
#define reset_LastError()
|
||||
#endif
|
||||
|
||||
|
@ -58,7 +58,7 @@ static void save_global_ini_value(const char *filename, const char *section, con
|
||||
new_ini.SetUnicode();
|
||||
new_ini.SetSpaces(false);
|
||||
|
||||
std::wstring fullpath(utf8_decode(Local_Storage::get_user_appdata_path() + Local_Storage::settings_storage_folder + PATH_SEPARATOR + filename));
|
||||
auto fullpath = utf8_decode(Local_Storage::get_user_appdata_path() + Local_Storage::settings_storage_folder + PATH_SEPARATOR + filename);
|
||||
if (!common_helpers::create_dir(fullpath)) return;
|
||||
|
||||
std::ifstream ini_file( fullpath, std::ios::binary | std::ios::in);
|
||||
@ -1095,17 +1095,15 @@ static void parse_build_id(class Settings *settings_client, class Settings *sett
|
||||
// main::general::crash_printer_location
|
||||
static void parse_crash_printer_location()
|
||||
{
|
||||
std::wstring crash_path{};
|
||||
std::string line(common_helpers::string_strip(Settings::sanitize(ini.GetValue("main::general", "crash_printer_location", ""))));
|
||||
if (line.size()) {
|
||||
crash_path = utf8_decode(common_helpers::to_absolute(line, get_full_program_path()));
|
||||
}
|
||||
|
||||
if (crash_path.size()) {
|
||||
if (crash_printer::init(crash_path)) {
|
||||
PRINT_DEBUG("Unhandled crashes will be saved to '%s'", utf8_encode(crash_path).c_str());
|
||||
} else {
|
||||
PRINT_DEBUG("Failed to setup unhandled crash printer with path: '%s'", utf8_encode(crash_path).c_str());
|
||||
auto crash_path = utf8_decode(common_helpers::to_absolute(line, get_full_program_path()));
|
||||
if (crash_path.size()) {
|
||||
if (crash_printer::init(crash_path)) {
|
||||
PRINT_DEBUG("Unhandled crashes will be saved to '%s'", utf8_encode(crash_path).c_str());
|
||||
} else {
|
||||
PRINT_DEBUG("Failed to setup unhandled crash printer with path: '%s'", utf8_encode(crash_path).c_str());
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user