1
0
mirror of https://github.com/xmrig/xmrig.git synced 2026-02-01 09:43:03 -05:00

Added DMI reader for macOS.

This commit is contained in:
XMRig
2021-01-19 14:16:03 +07:00
parent 9dffcdaddd
commit 24c290963a
4 changed files with 122 additions and 6 deletions

View File

@@ -70,6 +70,10 @@ bool xmrig::DmiReader::decode(uint8_t *buf)
while (static_cast<uint32_t>(next - buf + 1) < m_size && (next[0] != 0 || next[1] != 0)) {
next++;
}
# ifdef XMRIG_OS_APPLE
while ((unsigned long)(next - buf + 1) < m_size && (next[0] == 0 && next[1] == 0))
# endif
next += 2;
if (static_cast<uint32_t>(next - buf) > m_size) {