log: replace all NGLOG with LOG
This commit is contained in:
@ -38,12 +38,12 @@ public:
|
||||
|
||||
ResultVal<size_t> Read(u64 offset, size_t length, u8* buffer) const override {
|
||||
if (offset != 0) {
|
||||
NGLOG_ERROR(Service_FS, "offset must be zero!");
|
||||
LOG_ERROR(Service_FS, "offset must be zero!");
|
||||
return ERROR_UNSUPPORTED_OPEN_FLAGS;
|
||||
}
|
||||
|
||||
if (length != data->size()) {
|
||||
NGLOG_ERROR(Service_FS, "size must match the file size!");
|
||||
LOG_ERROR(Service_FS, "size must match the file size!");
|
||||
return ERROR_INCORRECT_EXEFS_READ_SIZE;
|
||||
}
|
||||
|
||||
@ -52,7 +52,7 @@ public:
|
||||
}
|
||||
|
||||
ResultVal<size_t> Write(u64 offset, size_t length, bool flush, const u8* buffer) override {
|
||||
NGLOG_ERROR(Service_FS, "The file is read-only!");
|
||||
LOG_ERROR(Service_FS, "The file is read-only!");
|
||||
return ERROR_UNSUPPORTED_OPEN_FLAGS;
|
||||
}
|
||||
|
||||
@ -88,13 +88,13 @@ public:
|
||||
// Note: SelfNCCHArchive doesn't check the open mode.
|
||||
|
||||
if (path.GetType() != LowPathType::Binary) {
|
||||
NGLOG_ERROR(Service_FS, "Path need to be Binary");
|
||||
LOG_ERROR(Service_FS, "Path need to be Binary");
|
||||
return ERROR_INVALID_PATH;
|
||||
}
|
||||
|
||||
std::vector<u8> binary = path.AsBinary();
|
||||
if (binary.size() != sizeof(SelfNCCHFilePath)) {
|
||||
NGLOG_ERROR(Service_FS, "Wrong path size {}", binary.size());
|
||||
LOG_ERROR(Service_FS, "Wrong path size {}", binary.size());
|
||||
return ERROR_INVALID_PATH;
|
||||
}
|
||||
|
||||
@ -109,7 +109,7 @@ public:
|
||||
return OpenRomFS();
|
||||
|
||||
case SelfNCCHFilePathType::Code:
|
||||
NGLOG_ERROR(Service_FS, "Reading the code section is not supported!");
|
||||
LOG_ERROR(Service_FS, "Reading the code section is not supported!");
|
||||
return ERROR_COMMAND_NOT_ALLOWED;
|
||||
|
||||
case SelfNCCHFilePathType::ExeFS: {
|
||||
@ -119,48 +119,48 @@ public:
|
||||
return OpenExeFS(filename);
|
||||
}
|
||||
default:
|
||||
NGLOG_ERROR(Service_FS, "Unknown file type {}!", static_cast<u32>(file_path.type));
|
||||
LOG_ERROR(Service_FS, "Unknown file type {}!", static_cast<u32>(file_path.type));
|
||||
return ERROR_INVALID_PATH;
|
||||
}
|
||||
}
|
||||
|
||||
ResultCode DeleteFile(const Path& path) const override {
|
||||
NGLOG_ERROR(Service_FS, "Unsupported");
|
||||
LOG_ERROR(Service_FS, "Unsupported");
|
||||
return ERROR_UNSUPPORTED_OPEN_FLAGS;
|
||||
}
|
||||
|
||||
ResultCode RenameFile(const Path& src_path, const Path& dest_path) const override {
|
||||
NGLOG_ERROR(Service_FS, "Unsupported");
|
||||
LOG_ERROR(Service_FS, "Unsupported");
|
||||
return ERROR_UNSUPPORTED_OPEN_FLAGS;
|
||||
}
|
||||
|
||||
ResultCode DeleteDirectory(const Path& path) const override {
|
||||
NGLOG_ERROR(Service_FS, "Unsupported");
|
||||
LOG_ERROR(Service_FS, "Unsupported");
|
||||
return ERROR_UNSUPPORTED_OPEN_FLAGS;
|
||||
}
|
||||
|
||||
ResultCode DeleteDirectoryRecursively(const Path& path) const override {
|
||||
NGLOG_ERROR(Service_FS, "Unsupported");
|
||||
LOG_ERROR(Service_FS, "Unsupported");
|
||||
return ERROR_UNSUPPORTED_OPEN_FLAGS;
|
||||
}
|
||||
|
||||
ResultCode CreateFile(const Path& path, u64 size) const override {
|
||||
NGLOG_ERROR(Service_FS, "Unsupported");
|
||||
LOG_ERROR(Service_FS, "Unsupported");
|
||||
return ERROR_UNSUPPORTED_OPEN_FLAGS;
|
||||
}
|
||||
|
||||
ResultCode CreateDirectory(const Path& path) const override {
|
||||
NGLOG_ERROR(Service_FS, "Unsupported");
|
||||
LOG_ERROR(Service_FS, "Unsupported");
|
||||
return ERROR_UNSUPPORTED_OPEN_FLAGS;
|
||||
}
|
||||
|
||||
ResultCode RenameDirectory(const Path& src_path, const Path& dest_path) const override {
|
||||
NGLOG_ERROR(Service_FS, "Unsupported");
|
||||
LOG_ERROR(Service_FS, "Unsupported");
|
||||
return ERROR_UNSUPPORTED_OPEN_FLAGS;
|
||||
}
|
||||
|
||||
ResultVal<std::unique_ptr<DirectoryBackend>> OpenDirectory(const Path& path) const override {
|
||||
NGLOG_ERROR(Service_FS, "Unsupported");
|
||||
LOG_ERROR(Service_FS, "Unsupported");
|
||||
return ERROR_UNSUPPORTED_OPEN_FLAGS;
|
||||
}
|
||||
|
||||
@ -177,7 +177,7 @@ private:
|
||||
std::make_unique<IVFCFile>(ncch_data.romfs_file, ncch_data.romfs_offset,
|
||||
ncch_data.romfs_size, std::move(delay_generator)));
|
||||
} else {
|
||||
NGLOG_INFO(Service_FS, "Unable to read RomFS");
|
||||
LOG_INFO(Service_FS, "Unable to read RomFS");
|
||||
return ERROR_ROMFS_NOT_FOUND;
|
||||
}
|
||||
}
|
||||
@ -190,7 +190,7 @@ private:
|
||||
ncch_data.update_romfs_file, ncch_data.update_romfs_offset,
|
||||
ncch_data.update_romfs_size, std::move(delay_generator)));
|
||||
} else {
|
||||
NGLOG_INFO(Service_FS, "Unable to read update RomFS");
|
||||
LOG_INFO(Service_FS, "Unable to read update RomFS");
|
||||
return ERROR_ROMFS_NOT_FOUND;
|
||||
}
|
||||
}
|
||||
@ -202,7 +202,7 @@ private:
|
||||
std::make_unique<ExeFSSectionFile>(ncch_data.icon));
|
||||
}
|
||||
|
||||
NGLOG_WARNING(Service_FS, "Unable to read icon");
|
||||
LOG_WARNING(Service_FS, "Unable to read icon");
|
||||
return ERROR_EXEFS_SECTION_NOT_FOUND;
|
||||
}
|
||||
|
||||
@ -212,7 +212,7 @@ private:
|
||||
std::make_unique<ExeFSSectionFile>(ncch_data.logo));
|
||||
}
|
||||
|
||||
NGLOG_WARNING(Service_FS, "Unable to read logo");
|
||||
LOG_WARNING(Service_FS, "Unable to read logo");
|
||||
return ERROR_EXEFS_SECTION_NOT_FOUND;
|
||||
}
|
||||
|
||||
@ -222,11 +222,11 @@ private:
|
||||
std::make_unique<ExeFSSectionFile>(ncch_data.banner));
|
||||
}
|
||||
|
||||
NGLOG_WARNING(Service_FS, "Unable to read banner");
|
||||
LOG_WARNING(Service_FS, "Unable to read banner");
|
||||
return ERROR_EXEFS_SECTION_NOT_FOUND;
|
||||
}
|
||||
|
||||
NGLOG_ERROR(Service_FS, "Unknown ExeFS section {}!", filename);
|
||||
LOG_ERROR(Service_FS, "Unknown ExeFS section {}!", filename);
|
||||
return ERROR_INVALID_PATH;
|
||||
}
|
||||
|
||||
@ -236,16 +236,16 @@ private:
|
||||
void ArchiveFactory_SelfNCCH::Register(Loader::AppLoader& app_loader) {
|
||||
u64 program_id = 0;
|
||||
if (app_loader.ReadProgramId(program_id) != Loader::ResultStatus::Success) {
|
||||
NGLOG_WARNING(
|
||||
LOG_WARNING(
|
||||
Service_FS,
|
||||
"Could not read program id when registering with SelfNCCH, this might be a 3dsx file");
|
||||
}
|
||||
|
||||
NGLOG_DEBUG(Service_FS, "Registering program {:016X} with the SelfNCCH archive factory",
|
||||
LOG_DEBUG(Service_FS, "Registering program {:016X} with the SelfNCCH archive factory",
|
||||
program_id);
|
||||
|
||||
if (ncch_data.find(program_id) != ncch_data.end()) {
|
||||
NGLOG_WARNING(Service_FS,
|
||||
LOG_WARNING(Service_FS,
|
||||
"Registering program {:016X} with SelfNCCH will override existing mapping",
|
||||
program_id);
|
||||
}
|
||||
@ -288,12 +288,12 @@ ResultVal<std::unique_ptr<ArchiveBackend>> ArchiveFactory_SelfNCCH::Open(const P
|
||||
}
|
||||
|
||||
ResultCode ArchiveFactory_SelfNCCH::Format(const Path&, const FileSys::ArchiveFormatInfo&) {
|
||||
NGLOG_ERROR(Service_FS, "Attempted to format a SelfNCCH archive.");
|
||||
LOG_ERROR(Service_FS, "Attempted to format a SelfNCCH archive.");
|
||||
return ERROR_INVALID_PATH;
|
||||
}
|
||||
|
||||
ResultVal<ArchiveFormatInfo> ArchiveFactory_SelfNCCH::GetFormatInfo(const Path&) const {
|
||||
NGLOG_ERROR(Service_FS, "Attempted to get format info of a SelfNCCH archive");
|
||||
LOG_ERROR(Service_FS, "Attempted to get format info of a SelfNCCH archive");
|
||||
return ERROR_INVALID_PATH;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user