ams: use util::SNPrintf over std:: (size/linker improvements)

This commit is contained in:
Michael Scire 2021-01-12 02:59:41 -08:00
parent 9cfd259c5c
commit 094cede39e
41 changed files with 103 additions and 103 deletions

View file

@ -26,7 +26,7 @@ namespace ams::dmnt::cheat::impl {
fs::FileHandle log_file;
{
char log_path[fs::EntryNameLengthMax + 1];
std::snprintf(log_path, sizeof(log_path), "sdmc:/atmosphere/cheat_vm_logs/%08x.log", log_id);
util::SNPrintf(log_path, sizeof(log_path), "sdmc:/atmosphere/cheat_vm_logs/%08x.log", log_id);
if (R_FAILED(fs::OpenFile(std::addressof(log_file), log_path, fs::OpenMode_Write | fs::OpenMode_AllowAppend))) {
return;
}
@ -39,7 +39,7 @@ namespace ams::dmnt::cheat::impl {
}
char log_value[18];
std::snprintf(log_value, sizeof(log_value), "%016lx\n", value);
util::SNPrintf(log_value, sizeof(log_value), "%016lx\n", value);
fs::WriteFile(log_file, log_offset, log_value, std::strlen(log_value), fs::WriteOption::Flush);
}
@ -69,7 +69,7 @@ namespace ams::dmnt::cheat::impl {
{
std::va_list vl;
va_start(vl, format);
std::vsnprintf(this->debug_log_format_buf, sizeof(this->debug_log_format_buf) - 1, format, vl);
util::VSNPrintf(this->debug_log_format_buf, sizeof(this->debug_log_format_buf) - 1, format, vl);
va_end(vl);
}