From 6fe545b3e951c57ea266763f141467530d86e8f2 Mon Sep 17 00:00:00 2001 From: gibbed Date: Thu, 14 May 2015 17:01:40 -0500 Subject: [PATCH] Return X_ERROR_PATH_NOT_FOUND instead of X_ERROR_FILE_NOT_FOUND in XamContentCreateCore. --- src/xenia/kernel/xam_content.cc | 4 ++-- src/xenia/xbox.h | 1 + 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/xenia/kernel/xam_content.cc b/src/xenia/kernel/xam_content.cc index aac8178fc..f7c92322f 100644 --- a/src/xenia/kernel/xam_content.cc +++ b/src/xenia/kernel/xam_content.cc @@ -265,7 +265,7 @@ void XamContentCreateCore(PPCContext* ppc_state, KernelState* state, case 3: // OPEN_EXISTING // Open only if exists. if (!content_manager->ContentExists(content_data)) { - result = X_ERROR_FILE_NOT_FOUND; + result = X_ERROR_PATH_NOT_FOUND; } else { open = true; } @@ -281,7 +281,7 @@ void XamContentCreateCore(PPCContext* ppc_state, KernelState* state, case 5: // TRUNCATE_EXISTING // Fail if doesn't exist, if does exist delete and recreate. if (!content_manager->ContentExists(content_data)) { - result = X_ERROR_FILE_NOT_FOUND; + result = X_ERROR_PATH_NOT_FOUND; } else { content_manager->DeleteContent(content_data); create = true; diff --git a/src/xenia/xbox.h b/src/xenia/xbox.h index 7d03fab39..0dc52f471 100644 --- a/src/xenia/xbox.h +++ b/src/xenia/xbox.h @@ -72,6 +72,7 @@ typedef uint32_t X_RESULT; #define X_RESULT_FROM_WIN32(x) x //((X_RESULT)(x) <= 0 ? ((X_RESULT)(x)) : ((X_RESULT) (((x) & 0x0000FFFF) | (X_FACILITY_WIN32 << 16) | 0x80000000))) #define X_ERROR_SUCCESS X_RESULT_FROM_WIN32(0x00000000L) #define X_ERROR_FILE_NOT_FOUND X_RESULT_FROM_WIN32(0x00000002L) +#define X_ERROR_PATH_NOT_FOUND X_RESULT_FROM_WIN32(0x00000003L) #define X_ERROR_ACCESS_DENIED X_RESULT_FROM_WIN32(0x00000005L) #define X_ERROR_INVALID_HANDLE X_RESULT_FROM_WIN32(0x00000006L) #define X_ERROR_NO_MORE_FILES X_RESULT_FROM_WIN32(0x00000018L)