Ejemplo n.º 1
0
        public void AfterStartMining()
        {
            int pid = _miningProcess?.Id ?? -1;

            // TODO C# can have this shorter
            if (_affinityMask != 0 && pid != -1)
            {
                var okMsg = ProcessHelpers.AdjustAffinity(pid, _affinityMask);
                Logger.Info(_logGroup, $"Adjust Affinity returned: {okMsg.Item2}");
            }
        }
Ejemplo n.º 2
0
        public void AfterStartMining()
        {
            int pid = -1;

            if (_miningProcess != null && _miningProcess.Handle != null)
            {
                pid = _miningProcess.Handle.Id;
            }
            // TODO C# can have this shorter
            if (_affinityMask != 0 && pid != -1)
            {
                var(ok, msg) = ProcessHelpers.AdjustAffinity(pid, _affinityMask);
                // TODO log what is going on is it ok or not
            }
        }