Merge pull request #2945 from FernandoS27/fix-bcat
nifm: Only return that there's an internet connection when there's a BCATServer
This commit is contained in:
commit
6fe51f398f
|
@ -9,6 +9,7 @@
|
||||||
#include "core/hle/kernel/writable_event.h"
|
#include "core/hle/kernel/writable_event.h"
|
||||||
#include "core/hle/service/nifm/nifm.h"
|
#include "core/hle/service/nifm/nifm.h"
|
||||||
#include "core/hle/service/service.h"
|
#include "core/hle/service/service.h"
|
||||||
|
#include "core/settings.h"
|
||||||
|
|
||||||
namespace Service::NIFM {
|
namespace Service::NIFM {
|
||||||
|
|
||||||
|
@ -86,8 +87,13 @@ private:
|
||||||
|
|
||||||
IPC::ResponseBuilder rb{ctx, 3};
|
IPC::ResponseBuilder rb{ctx, 3};
|
||||||
rb.Push(RESULT_SUCCESS);
|
rb.Push(RESULT_SUCCESS);
|
||||||
|
|
||||||
|
if (Settings::values.bcat_backend == "none") {
|
||||||
|
rb.PushEnum(RequestState::NotSubmitted);
|
||||||
|
} else {
|
||||||
rb.PushEnum(RequestState::Connected);
|
rb.PushEnum(RequestState::Connected);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
void GetResult(Kernel::HLERequestContext& ctx) {
|
void GetResult(Kernel::HLERequestContext& ctx) {
|
||||||
LOG_WARNING(Service_NIFM, "(STUBBED) called");
|
LOG_WARNING(Service_NIFM, "(STUBBED) called");
|
||||||
|
@ -194,15 +200,23 @@ private:
|
||||||
|
|
||||||
IPC::ResponseBuilder rb{ctx, 3};
|
IPC::ResponseBuilder rb{ctx, 3};
|
||||||
rb.Push(RESULT_SUCCESS);
|
rb.Push(RESULT_SUCCESS);
|
||||||
|
if (Settings::values.bcat_backend == "none") {
|
||||||
|
rb.Push<u8>(0);
|
||||||
|
} else {
|
||||||
rb.Push<u8>(1);
|
rb.Push<u8>(1);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
void IsAnyInternetRequestAccepted(Kernel::HLERequestContext& ctx) {
|
void IsAnyInternetRequestAccepted(Kernel::HLERequestContext& ctx) {
|
||||||
LOG_WARNING(Service_NIFM, "(STUBBED) called");
|
LOG_WARNING(Service_NIFM, "(STUBBED) called");
|
||||||
|
|
||||||
IPC::ResponseBuilder rb{ctx, 3};
|
IPC::ResponseBuilder rb{ctx, 3};
|
||||||
rb.Push(RESULT_SUCCESS);
|
rb.Push(RESULT_SUCCESS);
|
||||||
|
if (Settings::values.bcat_backend == "none") {
|
||||||
|
rb.Push<u8>(0);
|
||||||
|
} else {
|
||||||
rb.Push<u8>(1);
|
rb.Push<u8>(1);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
Core::System& system;
|
Core::System& system;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue