mirror of
https://github.com/switchbrew/libnx.git
synced 2025-07-05 02:52:13 +02:00
nfc: add missing argument in nfpuOpenApplicationArea.
This commit is contained in:
parent
e9b458993b
commit
ff144c492a
@ -161,7 +161,7 @@ Result nfpuGetRegisterInfo(HidControllerID id, NfpuRegisterInfo *out);
|
|||||||
Result nfpuGetCommonInfo(HidControllerID id, NfpuCommonInfo *out);
|
Result nfpuGetCommonInfo(HidControllerID id, NfpuCommonInfo *out);
|
||||||
Result nfpuGetModelInfo(HidControllerID id, NfpuModelInfo *out);
|
Result nfpuGetModelInfo(HidControllerID id, NfpuModelInfo *out);
|
||||||
|
|
||||||
Result nfpuOpenApplicationArea(HidControllerID id, NfpuAppId app_id);
|
Result nfpuOpenApplicationArea(HidControllerID id, NfpuAppId app_id, u32* area_size);
|
||||||
Result nfpuGetApplicationArea(HidControllerID id, void* buf, size_t buf_size);
|
Result nfpuGetApplicationArea(HidControllerID id, void* buf, size_t buf_size);
|
||||||
|
|
||||||
/// Calls nfc:user.
|
/// Calls nfc:user.
|
||||||
|
@ -609,9 +609,9 @@ inline Result nfpuGetModelInfo(HidControllerID id, NfpuModelInfo *out) {
|
|||||||
return _nfpuInterfaceCmdInIdOutBuffer(&g_nfpuInterface, 16, id, out, sizeof(NfpuModelInfo));
|
return _nfpuInterfaceCmdInIdOutBuffer(&g_nfpuInterface, 16, id, out, sizeof(NfpuModelInfo));
|
||||||
}
|
}
|
||||||
|
|
||||||
Result nfpuOpenApplicationArea(HidControllerID id, NfpuAppId app_id) {
|
Result nfpuOpenApplicationArea(HidControllerID id, NfpuAppId app_id, u32* area_size) {
|
||||||
if (id == CONTROLLER_P1_AUTO)
|
if (id == CONTROLLER_P1_AUTO)
|
||||||
return nfpuOpenApplicationArea(g_controllerP1AutoID, app_id);
|
return nfpuOpenApplicationArea(g_controllerP1AutoID, app_id, area_size);
|
||||||
|
|
||||||
IpcCommand c;
|
IpcCommand c;
|
||||||
ipcInitialize(&c);
|
ipcInitialize(&c);
|
||||||
@ -637,12 +637,16 @@ Result nfpuOpenApplicationArea(HidControllerID id, NfpuAppId app_id) {
|
|||||||
struct {
|
struct {
|
||||||
u64 magic;
|
u64 magic;
|
||||||
u64 result;
|
u64 result;
|
||||||
|
u32 area_size;
|
||||||
} *resp;
|
} *resp;
|
||||||
|
|
||||||
serviceIpcParse(&g_nfpuInterface, &r, sizeof(*resp));
|
serviceIpcParse(&g_nfpuInterface, &r, sizeof(*resp));
|
||||||
resp = r.Raw;
|
resp = r.Raw;
|
||||||
|
|
||||||
rc = resp->result;
|
rc = resp->result;
|
||||||
|
|
||||||
|
if (R_SUCCEEDED(rc) && area_size)
|
||||||
|
*area_size = resp->area_size;
|
||||||
}
|
}
|
||||||
|
|
||||||
return rc;
|
return rc;
|
||||||
|
Loading…
Reference in New Issue
Block a user