Code formatting, TryGetValue
This commit is contained in:
parent
b12017344a
commit
2c05bce562
1 changed files with 7 additions and 2 deletions
|
@ -9,14 +9,17 @@ namespace Ryujinx.HLE.OsHle.Services.Nv.NvHostCtrl
|
||||||
class NvHostCtrlIoctl
|
class NvHostCtrlIoctl
|
||||||
{
|
{
|
||||||
private static ConcurrentDictionary<Process, NvHostCtrlUserCtx> UserCtxs;
|
private static ConcurrentDictionary<Process, NvHostCtrlUserCtx> UserCtxs;
|
||||||
|
|
||||||
private static bool IsProductionMode = true;
|
private static bool IsProductionMode = true;
|
||||||
|
|
||||||
static NvHostCtrlIoctl()
|
static NvHostCtrlIoctl()
|
||||||
{
|
{
|
||||||
UserCtxs = new ConcurrentDictionary<Process, NvHostCtrlUserCtx>();
|
UserCtxs = new ConcurrentDictionary<Process, NvHostCtrlUserCtx>();
|
||||||
if(Set.NxSettings.Settings.ContainsKey("nv!rmos_set_production_mode"))
|
|
||||||
|
Set.NxSettings.Settings.TryGetValue("", out object ProductionModeSetting);
|
||||||
|
if (ProductionModeSetting != null)
|
||||||
{
|
{
|
||||||
IsProductionMode = Set.NxSettings.Settings["nv!rmos_set_production_mode"].ToString() != "0"; // Default value is ""
|
IsProductionMode = ProductionModeSetting.ToString() != "0"; // Default value is ""
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -87,8 +90,10 @@ namespace Ryujinx.HLE.OsHle.Services.Nv.NvHostCtrl
|
||||||
Context.Memory.WriteByte(OutputPosition + 0x82, (byte)'0');
|
Context.Memory.WriteByte(OutputPosition + 0x82, (byte)'0');
|
||||||
|
|
||||||
Context.Ns.Log.PrintStub(LogClass.ServiceNv, "Stubbed.");
|
Context.Ns.Log.PrintStub(LogClass.ServiceNv, "Stubbed.");
|
||||||
|
|
||||||
return NvResult.Success;
|
return NvResult.Success;
|
||||||
}
|
}
|
||||||
|
|
||||||
return NvResult.NotAvailableInProduction;
|
return NvResult.NotAvailableInProduction;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue