Skip to content

Commit 25d9880

Browse files
committed
Updated examples to pass ServiceType to the relevant *Initialize() funcs, as required by latest libnx.
1 parent b9df83b commit 25d9880

File tree

4 files changed

+5
-5
lines changed

4 files changed

+5
-5
lines changed

account/source/main.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ int main(int argc, char **argv)
2121
memset(&userdata, 0, sizeof(userdata));
2222
memset(&profilebase, 0, sizeof(profilebase));
2323

24-
rc = accountInitialize();
24+
rc = accountInitialize(AccountServiceType_Application);
2525
if (R_FAILED(rc)) {
2626
printf("accountInitialize() failed: 0x%x\n", rc);
2727
}

applet/app-playstats/source/main.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ int main(int argc, char* argv[])
3232

3333
// Only needed when using the cmds which require the Uid.
3434
AccountUid preselected_uid={0};
35-
rc = accountInitialize();
35+
rc = accountInitialize(AccountServiceType_Application);
3636
if (R_SUCCEEDED(rc)) {
3737
rc = accountGetPreselectedUser(&preselected_uid);
3838
accountExit();

fs/save/source/main.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ int main(int argc, char **argv)
5555
//See the account example for getting account info for an userID.
5656
//See also the app_controldata example for getting info for an application_id.
5757
if (R_FAILED(get_save(&application_id, &uid))) {
58-
rc = accountInitialize();
58+
rc = accountInitialize(AccountServiceType_Application);
5959
if (R_FAILED(rc)) {
6060
printf("accountInitialize() failed: 0x%x\n", rc);
6161
}

nfc/source/main.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -187,11 +187,11 @@ int main(int argc, char* argv[])
187187
consoleUpdate(NULL);
188188

189189
// Initialize the nfp:* service.
190-
rc = nfpInitialize();
190+
rc = nfpInitialize(NfpServiceType_User);
191191

192192
// Check if NFC is enabled. If not, wait until it is.
193193
// Note that various official games don't use nfc*().
194-
if (R_SUCCEEDED(rc)) rc = nfcInitialize();
194+
if (R_SUCCEEDED(rc)) rc = nfcInitialize(NfcServiceType_User);
195195
if (R_SUCCEEDED(rc)) {
196196
bool nfc_enabled = false;
197197
rc = nfcIsNfcEnabled(&nfc_enabled);

0 commit comments

Comments
 (0)