mirror of
https://github.com/RPCSX/rpcsx.git
synced 2026-04-20 22:05:12 +00:00
Remove legacy LOADER log channel
This commit is contained in:
parent
d9a0619ddd
commit
3eca2d5d6c
17 changed files with 377 additions and 361 deletions
|
|
@ -1,6 +1,8 @@
|
|||
#include "stdafx.h"
|
||||
#include "PSF.h"
|
||||
|
||||
LOG_CHANNEL(psf_log);
|
||||
|
||||
template<>
|
||||
void fmt_class_string<psf::format>::format(std::string& out, u64 arg)
|
||||
{
|
||||
|
|
@ -176,7 +178,7 @@ namespace psf
|
|||
else
|
||||
{
|
||||
// Possibly unsupported format, entry ignored
|
||||
LOG_ERROR(LOADER, "Unknown entry format (key='%s', fmt=0x%x, len=0x%x, max=0x%x)", key, indices[i].param_fmt, indices[i].param_len, indices[i].param_max);
|
||||
psf_log.error("Unknown entry format (key='%s', fmt=0x%x, len=0x%x, max=0x%x)", key, indices[i].param_fmt, indices[i].param_len, indices[i].param_max);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -250,7 +252,7 @@ namespace psf
|
|||
if (value.size() + (fmt == format::string) > max)
|
||||
{
|
||||
// TODO: check real limitations of PSF format
|
||||
LOG_ERROR(LOADER, "Entry value shrinkage (key='%s', value='%s', size=0x%zx, max=0x%x)", entry.first, value, size, max);
|
||||
psf_log.error("Entry value shrinkage (key='%s', value='%s', size=0x%zx, max=0x%x)", entry.first, value, size, max);
|
||||
}
|
||||
|
||||
stream.write(value);
|
||||
|
|
|
|||
|
|
@ -5,6 +5,8 @@
|
|||
#include "Emu/System.h"
|
||||
#include "TROPUSR.h"
|
||||
|
||||
LOG_CHANNEL(trp_log);
|
||||
|
||||
bool TROPUSRLoader::Load(const std::string& filepath, const std::string& configpath)
|
||||
{
|
||||
const std::string& path = vfs::get(filepath);
|
||||
|
|
@ -223,13 +225,13 @@ u32 TROPUSRLoader::GetUnlockedPlatinumID(u32 trophy_id, const std::string& confi
|
|||
|
||||
if (trophy_id >= m_table6.size() || trophy_id >= m_table4.size())
|
||||
{
|
||||
LOG_WARNING(LOADER, "TROPUSRLoader::GetUnlockedPlatinumID: Invalid id=%d", trophy_id);
|
||||
trp_log.warning("TROPUSRLoader::GetUnlockedPlatinumID: Invalid id=%d", trophy_id);
|
||||
return invalid_trophy_id;
|
||||
}
|
||||
|
||||
if (m_table6.size() != m_table4.size())
|
||||
{
|
||||
LOG_WARNING(LOADER, "TROPUSRLoader::GetUnlockedPlatinumID: Table size mismatch: %d vs. %d", m_table6.size(), m_table4.size());
|
||||
trp_log.warning("TROPUSRLoader::GetUnlockedPlatinumID: Table size mismatch: %d vs. %d", m_table6.size(), m_table4.size());
|
||||
return invalid_trophy_id;
|
||||
}
|
||||
|
||||
|
|
@ -295,7 +297,7 @@ u32 TROPUSRLoader::GetTrophyGrade(u32 id)
|
|||
{
|
||||
if (id >= m_table4.size())
|
||||
{
|
||||
LOG_WARNING(LOADER, "TROPUSRLoader::GetTrophyGrade: Invalid id=%d", id);
|
||||
trp_log.warning("TROPUSRLoader::GetTrophyGrade: Invalid id=%d", id);
|
||||
return trophy_grade::unknown;
|
||||
}
|
||||
|
||||
|
|
@ -306,7 +308,7 @@ u32 TROPUSRLoader::GetTrophyUnlockState(u32 id)
|
|||
{
|
||||
if (id >= m_table6.size())
|
||||
{
|
||||
LOG_WARNING(LOADER, "TROPUSRLoader::GetTrophyUnlockState: Invalid id=%d", id);
|
||||
trp_log.warning("TROPUSRLoader::GetTrophyUnlockState: Invalid id=%d", id);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
@ -317,7 +319,7 @@ u64 TROPUSRLoader::GetTrophyTimestamp(u32 id)
|
|||
{
|
||||
if (id >= m_table6.size())
|
||||
{
|
||||
LOG_WARNING(LOADER, "TROPUSRLoader::GetTrophyTimestamp: Invalid id=%d", id);
|
||||
trp_log.warning("TROPUSRLoader::GetTrophyTimestamp: Invalid id=%d", id);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
@ -329,7 +331,7 @@ bool TROPUSRLoader::UnlockTrophy(u32 id, u64 timestamp1, u64 timestamp2)
|
|||
{
|
||||
if (id >= m_table6.size())
|
||||
{
|
||||
LOG_WARNING(LOADER, "TROPUSRLoader::UnlockTrophy: Invalid id=%d", id);
|
||||
trp_log.warning("TROPUSRLoader::UnlockTrophy: Invalid id=%d", id);
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -4,6 +4,8 @@
|
|||
#include "Crypto/sha1.h"
|
||||
#include "Utilities/StrUtil.h"
|
||||
|
||||
LOG_CHANNEL(trp_log);
|
||||
|
||||
TRPLoader::TRPLoader(const fs::file& f)
|
||||
: trp_f(f)
|
||||
{
|
||||
|
|
@ -57,7 +59,7 @@ bool TRPLoader::LoadHeader(bool show)
|
|||
|
||||
if (show)
|
||||
{
|
||||
LOG_NOTICE(LOADER, "TRP version: 0x%x", m_header.trp_version);
|
||||
trp_log.notice("TRP version: 0x%x", m_header.trp_version);
|
||||
}
|
||||
|
||||
if (m_header.trp_version >= 2)
|
||||
|
|
@ -68,7 +70,7 @@ bool TRPLoader::LoadHeader(bool show)
|
|||
trp_f.seek(0);
|
||||
if (!trp_f.read(file_contents))
|
||||
{
|
||||
LOG_NOTICE(LOADER, "Failed verifying checksum");
|
||||
trp_log.notice("Failed verifying checksum");
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
@ -77,7 +79,7 @@ bool TRPLoader::LoadHeader(bool show)
|
|||
|
||||
if (memcmp(hash, m_header.sha1, 20) != 0)
|
||||
{
|
||||
LOG_ERROR(LOADER, "Invalid checksum of TROPHY.TRP file");
|
||||
trp_log.error("Invalid checksum of TROPHY.TRP file");
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
|
@ -97,7 +99,7 @@ bool TRPLoader::LoadHeader(bool show)
|
|||
|
||||
if (show)
|
||||
{
|
||||
LOG_NOTICE(LOADER, "TRP entry #%d: %s", m_entries[i].name);
|
||||
trp_log.notice("TRP entry #%d: %s", m_entries[i].name);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue