Fix FSPXI_CreateFile and FSPXI_WriteFile (#496)

This commit is contained in:
ZeroSkill 2022-06-29 19:19:50 +03:00 committed by GitHub
parent 10cf9bb95a
commit 607f1d1fb6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -107,8 +107,8 @@ Result FSPXI_CreateFile(Handle serviceHandle, FSPXI_Archive archive, FS_Path pat
cmdbuf[6] = attributes;
cmdbuf[7] = (u32)fileSize;
cmdbuf[8] = (u32)(fileSize >> 32);
cmdbuf[8] = IPC_Desc_PXIBuffer(path.size, 0, true);
cmdbuf[9] = (u32) path.data;
cmdbuf[9] = IPC_Desc_PXIBuffer(path.size, 0, true);
cmdbuf[10] = (u32) path.data;
if(R_FAILED(ret = svcSendSyncRequest(serviceHandle))) return ret;
@ -229,8 +229,8 @@ Result FSPXI_WriteFile(Handle serviceHandle, FSPXI_File file, u32* bytesWritten,
cmdbuf[2] = (u32)(file >> 32);
cmdbuf[3] = (u32) offset;
cmdbuf[4] = (u32) (offset >> 32);
cmdbuf[5] = flags;
cmdbuf[6] = size;
cmdbuf[5] = size;
cmdbuf[6] = flags;
cmdbuf[7] = IPC_Desc_PXIBuffer(size, 0, true);
cmdbuf[8] = (u32) buffer;