Return X_ERROR_PATH_NOT_FOUND instead of X_ERROR_FILE_NOT_FOUND in XamContentCreateCore.

This commit is contained in:
gibbed 2015-05-14 17:01:40 -05:00
parent 61f4095851
commit 6fe545b3e9
2 changed files with 3 additions and 2 deletions

View File

@ -265,7 +265,7 @@ void XamContentCreateCore(PPCContext* ppc_state, KernelState* state,
case 3: // OPEN_EXISTING case 3: // OPEN_EXISTING
// Open only if exists. // Open only if exists.
if (!content_manager->ContentExists(content_data)) { if (!content_manager->ContentExists(content_data)) {
result = X_ERROR_FILE_NOT_FOUND; result = X_ERROR_PATH_NOT_FOUND;
} else { } else {
open = true; open = true;
} }
@ -281,7 +281,7 @@ void XamContentCreateCore(PPCContext* ppc_state, KernelState* state,
case 5: // TRUNCATE_EXISTING case 5: // TRUNCATE_EXISTING
// Fail if doesn't exist, if does exist delete and recreate. // Fail if doesn't exist, if does exist delete and recreate.
if (!content_manager->ContentExists(content_data)) { if (!content_manager->ContentExists(content_data)) {
result = X_ERROR_FILE_NOT_FOUND; result = X_ERROR_PATH_NOT_FOUND;
} else { } else {
content_manager->DeleteContent(content_data); content_manager->DeleteContent(content_data);
create = true; create = true;

View File

@ -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_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_SUCCESS X_RESULT_FROM_WIN32(0x00000000L)
#define X_ERROR_FILE_NOT_FOUND X_RESULT_FROM_WIN32(0x00000002L) #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_ACCESS_DENIED X_RESULT_FROM_WIN32(0x00000005L)
#define X_ERROR_INVALID_HANDLE X_RESULT_FROM_WIN32(0x00000006L) #define X_ERROR_INVALID_HANDLE X_RESULT_FROM_WIN32(0x00000006L)
#define X_ERROR_NO_MORE_FILES X_RESULT_FROM_WIN32(0x00000018L) #define X_ERROR_NO_MORE_FILES X_RESULT_FROM_WIN32(0x00000018L)