summaryrefslogtreecommitdiffstats
path: root/src/core/hle/service/cfg
diff options
context:
space:
mode:
authorYuri Kunde Schlesner <yuriks@yuriks.net>2017-05-21 06:41:11 +0200
committerYuri Kunde Schlesner <yuriks@yuriks.net>2017-05-25 06:06:00 +0200
commit92be29adba56408685e594e5e659f1dc83686cde (patch)
tree09afef886d4eb26e4f752dc9b93c81ea21d87d9c /src/core/hle/service/cfg
parentresult: Make error description a generic integer (diff)
downloadyuzu-92be29adba56408685e594e5e659f1dc83686cde.tar
yuzu-92be29adba56408685e594e5e659f1dc83686cde.tar.gz
yuzu-92be29adba56408685e594e5e659f1dc83686cde.tar.bz2
yuzu-92be29adba56408685e594e5e659f1dc83686cde.tar.lz
yuzu-92be29adba56408685e594e5e659f1dc83686cde.tar.xz
yuzu-92be29adba56408685e594e5e659f1dc83686cde.tar.zst
yuzu-92be29adba56408685e594e5e659f1dc83686cde.zip
Diffstat (limited to 'src/core/hle/service/cfg')
-rw-r--r--src/core/hle/service/cfg/cfg.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/core/hle/service/cfg/cfg.cpp b/src/core/hle/service/cfg/cfg.cpp
index 14185ae20..caa41ded7 100644
--- a/src/core/hle/service/cfg/cfg.cpp
+++ b/src/core/hle/service/cfg/cfg.cpp
@@ -11,6 +11,7 @@
#include "common/string_util.h"
#include "common/swap.h"
#include "core/file_sys/archive_systemsavedata.h"
+#include "core/file_sys/errors.h"
#include "core/file_sys/file_backend.h"
#include "core/hle/result.h"
#include "core/hle/service/cfg/cfg.h"
@@ -411,8 +412,7 @@ ResultCode UpdateConfigNANDSavegame() {
ResultCode FormatConfig() {
ResultCode res = DeleteConfigNANDSaveFile();
// The delete command fails if the file doesn't exist, so we have to check that too
- if (!res.IsSuccess() &&
- res.description != static_cast<u32>(ErrorDescription::FS_FileNotFound)) {
+ if (!res.IsSuccess() && res != FileSys::ERROR_FILE_NOT_FOUND) {
return res;
}
// Delete the old data
@@ -535,7 +535,7 @@ ResultCode LoadConfigNANDSaveFile() {
Service::FS::OpenArchive(Service::FS::ArchiveIdCode::SystemSaveData, archive_path);
// If the archive didn't exist, create the files inside
- if (archive_result.Code().description == static_cast<u32>(ErrorDescription::FS_NotFormatted)) {
+ if (archive_result.Code() == FileSys::ERR_NOT_FORMATTED) {
// Format the archive to create the directories
Service::FS::FormatArchive(Service::FS::ArchiveIdCode::SystemSaveData,
FileSys::ArchiveFormatInfo(), archive_path);